According to the MR Dang investment system, conductstandardized risk screening + multi-dimensional scoring + investment ratingon A-share listed companies. Automatically through Tushare to obtain financial/valuation/dividend data + Jina search to supplement business/industry/risk information。
Core Rules
- One-vote veto: Dividend yield < 2% is directly eliminated
- Passing line: ≥60 points can enter in-depth research
- Core logic: Focus on excluding risks, not pursuing perfect companies
- Applicable industries: Banking, resources, chemicals/manufacturing, utilities, other traditional industries
Trigger Methods
User input examples:
- MR Dang stock picking
<股票名称> - MR Dang scoring
<股票名称><行业类型> - Help me analyze using the MR Dang system
<股票代码>
Automatic trigger scenarios(without the user explicitly mentioning MR Dang):
- The user asks whether a certain A-share is worth investing in / can be bought
- The user mentions dividend yield or dividend stability screening
- The user asks about the investment value of bank stocks / resource stocks / cyclical stocks / utility stocks
- The user needs stock valuation judgment (PE/PB analysis)
- The user mentions concepts such as "value investing", "margin of safety", "high dividend"
Available Scripts
| Script | Purpose |
|---|---|
scripts/data.py |
Obtain stock data from Tushare |
scripts/search.py |
Search web information through Jina |
All scripts follow the PEP 723 standard, include built-in dependency declarations, and can be executed directly with uv run , without manually installing dependencies.
API Key secure configuration:
The script loads API Keys uniformly through scripts/_keys.py , with loading priority: environment variables > current directory .env file.
Recommended practice: create in thecurrent working directory(not the skill directory) a .env file:
TUSHARE_TOKEN=your_token_here
JINA_API_KEY=your_key_here
.env is already excluded in the repository .gitignore and will not be committed.
Supported environment variables:
TUSHARE_TOKENorTUSHARE_API_KEY— Tushare API Token (required, choose one of the two)JINA_API_KEY— Jina API Key (optional, increases search quota)
It is forbidden to paste API Keys directly into the conversation context.
Execution Flow
Step 1: Obtain the stock code
If the user provides a stock name, first use Tushare to query the stock code:
uv run scripts/data.py search <股票名称或代码>
The output includes information such as ts_code, name, industry, and listing date.
Step 2: Obtain Tushare structured data
Use Tushare to obtain the following data:
# 获取所有数据(推荐)
uv run scripts/data.py get <ts_code> --type all
# 获取基础信息
uv run scripts/data.py get <ts_code> --type basic
# 获取每日指标 (PE, PB, 市值等)
uv run scripts/data.py get <ts_code> --type daily
# 获取财务指标
uv run scripts/data.py get <ts_code> --type financial
# 获取完整财务指标(多期)
uv run scripts/data.py get <ts_code> --type financial-full --periods 8
# 获取分红信息
uv run scripts/data.py get <ts_code> --type dividend --years 5
# 获取日线行情
uv run scripts/data.py get <ts_code> --type ohlcv --days 250
# 获取股价位置判断
uv run scripts/data.py get <ts_code> --type price
Core fields that must be obtained:
- PE(TTM), PB, total market value, circulating market value
- Debt-to-asset ratio, operating cash flow, ROE
- Dividend yield over the past 1 year, dividend stability over the past 3 years, payout ratio
- Recent additional issuance/share unlock situation
Step 3: Jina search for unstructured information
Use scripts/search.py to search for the following:
# 搜索公司全面信息
uv run scripts/search.py company <公司名称> --industry <行业>
# 单独搜索
uv run scripts/search.py query "<公司名称> 主营业务" --max-results 5
uv run scripts/search.py query "<公司名称> 行业地位" --include-domains eastmoney.com
# 从搜索结果提取摘要
uv run scripts/search.py extract results.json --max-length 500
Search template (auto-execute):
- Main business search:
{公司名称} 主营业务 业务构成 产品结构 - Industry position search:
{公司名称} 行业地位 竞争优势 市场份额 - Cyclicality assessment:
{公司名称} 是否周期股 产能周期 行业景气度 - Refinancing situation:
{公司名称} 增发 配股 再融资 近三年 - Asset attribute assessment:
{公司名称} 生产资料属性 重资产还是轻资产 - For bank stocks only:
{公司名称} 区域经济 房地产风险 不良率 拨备覆盖率
Step 4: Basic 5-item risk screening
Any failure leads to direct elimination:
- Is it a pure theme/story stock with no actual revenue or main business
- Is it a highly overvalued bubble stock (tech sector PE > 30 and no strong moat)
- Is it in an industry with severe involution and overcapacity
- Has it recently conducted high-level additional issuance or frequently raised funds
- Is the investment logic too complex to explain in three sentences
Step 5: 8-dimension scoring (total 100 points)
1. Means-of-production attributes (20 points)
- Resources/energy/utilities/banks/heavy assets: 18–20 points
- Stable manufacturing, channel-based: 10–17 points
- Asset-light, pure services, theme-based: 0–9 points
2. Dividend yield (20 points)
- ≥5%: 20 points
- 3%–5%: 15 points
- 2%–3%: 8 points
- <2%: 0 points (direct elimination)
3. Valuation (15 points)
- PE≤10 or PB at historical low percentile: 15 points
- PE 10–20: 10 points
- PE 20–30: 5 points
- PE>30: 0 points
4. Resource endowment / cost advantage (15 points)
Only enabled for resources/chemicals/manufacturing; skip other industries
- Own resources / top of industry in cost: 13–15 points
- Average cost, medium competitiveness: 6–12 points
- No advantage, high cost, tail-end enterprise: 0–5 points
5. Industry and competitive position (10 points)
- Industry leader/oligopoly/tight supply-demand: 8–10 points
- Medium position, mild competition: 4–7 points
- Tail-end, severe involution, price war: 0–3 points
6. Regional factors (10 points)
Only enabled for banks/regional stocks; skip others
- Economically developed, low risk: 8–10 points
- Average region: 4–7 points
- High-debt region, high real estate risk: 0–3 points
7. Liquidity and financial safety (5 points)
- Moderate market cap, healthy liabilities, stable cash flow: 4–5 points
- Small market cap, relatively high liabilities, volatile cash flow: 0–3 points
8. Clarity of logic (5 points)
Score based on business complexity.
Step 6: Total score rating
| Score | Rating | Action suggestion |
|---|---|---|
| 80–100 | ⭐⭐⭐⭐⭐ Excellent | Key focus, can build position |
| 60–79 | ⭐⭐⭐⭐ Good | Can buy in batches |
| 40–59 | ⭐⭐⭐ Average | Observe cautiously |
| 20–39 | ⭐⭐ Poor | Recommend avoiding |
| 0–19 | ⭐ Very poor | Directly exclude |
Step 7: 10-item pre-purchase checklist
For each item, judge: meets standard / doubtful / does not meet standard
- Can the buy logic be explained clearly in three sentences
- Does it have means-of-production attributes
- Dividend yield ≥ 3%
- PE≤20
- Stock price is not at a historical high
- The logic does not depend on short-term financial reports
- The logic is based on independent judgment
- Would still dare to add to the position after a 30% drop
- No cheaper and safer alternative
- Has a clear holding period
Behavioral constraints
- Data must be obtained first, then scored; no scoring by guesswork
- No embellishment, no self-persuasion; strictly follow the rules
- Missing data must be marked as [Insufficient data], not concealed
- Must state: This report is for investment reference only and does not constitute investment advice
- For bank stocks, must emphasize: A low PB does not mean undervaluation; asset quality must be considered
Output format
# MR Dang 选股打分报告
【标的】{股票名称}({ts_code})
【行业归类】{行业}
【分析日期】{日期}
---
## 一、基础筛查结果
| 筛查项 | 结果 | 说明 |
|--------|------|------|
| 题材股筛查 | 通过/淘汰 | |
| 高估值筛查 | 通过/淘汰 | |
| 产能过剩筛查 | 通过/淘汰 | |
| 增发圈钱筛查 | 通过/淘汰 | |
| 逻辑复杂度筛查 | 通过/淘汰 | |
**筛查结论**:通过 / 淘汰(原因:xxx)
---
## 二、核心数据概览
### 估值指标
| 指标 | 数值 | 说明 |
|------|------|------|
| PE(TTM) | | |
| PB | | |
| 总市值 | | |
| 流通市值 | | |
### 财务指标
| 指标 | 数值 | 说明 |
|------|------|------|
| 股息率(TTM) | | |
| 资产负债率 | | |
| ROE | | |
| 经营现金流 | | |
### 分红历史
| 指标 | 数值 | 说明 |
|------|------|------|
| 近3年分红次数 | | |
| 派息率 | | |
| 分红稳定性 | | |
### 业务概况
- **主营业务**:
- **行业地位**:
- **资源/成本优势**:
---
## 三、维度打分明细
| 维度 | 得分 | 满分 | 评分依据 |
|------|------|------|----------|
| 生产资料属性 | | 20 | |
| 股息率 | | 20 | |
| 估值 | | 15 | |
| 资源/成本优势 | | 15 | (如不适用标注 N/A)|
| 行业竞争位置 | | 10 | |
| 地域因素 | | 10 | (如不适用标注 N/A)|
| 流动性与财务安全 | | 5 | |
| 逻辑清晰度 | | 5 | |
**总分:__ / 100**
**评级:__ 星**
---
## 四、操作建议
{根据分数与股息率给出明确结论}
---
## 五、买入前清单核验
| 清单项 | 状态 | 说明 |
|--------|------|------|
| 三句话逻辑 | 达标/存疑 | |
| 生产资料属性 | 达标/存疑 | |
| 股息率≥3% | 达标/存疑 | |
| PE≤20 | 达标/存疑 | |
| 股价不在高位 | 达标/存疑 | |
| 不依赖短期财报 | 达标/存疑 | |
| 独立判断 | 达标/存疑 | |
| 跌30%敢加仓 | 达标/存疑 | |
| 无更优替代 | 达标/存疑 | |
| 明确持有周期 | 达标/存疑 | |
**达标项:X / 10**
---
## 六、综合结论
{简洁总结是否适合跟踪、买入、回避}
---
**风险提示**:本报告基于公开数据分析,不构成投资建议。投资有风险,入市需谨慎。
Available commands
Data retrieval (scripts/data.py)
| Command | Description |
|---|---|
uv run scripts/data.py search <关键词> |
Search stock code |
uv run scripts/data.py get <ts_code> --type basic |
Basic stock information |
uv run scripts/data.py get <ts_code> --type daily [--date YYYYMMDD] |
Daily indicators (PE, PB, market cap, etc.) |
uv run scripts/data.py get <ts_code> --type financial |
Financial indicator summary |
uv run scripts/data.py get <ts_code> --type financial-full [--periods N] |
Complete financial indicators |
uv run scripts/data.py get <ts_code> --type dividend [--years N] |
Dividend information |
uv run scripts/data.py get <ts_code> --type ohlcv [--days N] |
Daily price data |
uv run scripts/data.py get <ts_code> --type price [--days N] |
Stock price position assessment |
uv run scripts/data.py get <ts_code> --type all |
Retrieve all data |
Web search (scripts/search.py)
| Command | Description |
|---|---|
uv run scripts/search.py query <查询> [--max-results N] |
Jina search |
uv run scripts/search.py company <公司名> [--industry 行业] |
Search for comprehensive company information |
uv run scripts/search.py extract <json文件> [--max-length N] |
Extract search summary |
Example execution flow
User: MR Dang stock selection <股票名称>
Assistant executes:
# 1. 搜索股票代码
uv run scripts/data.py search <股票名称>
# 获取 ts_code 和行业信息
# 2. 获取 Tushare 数据
uv run scripts/data.py get <ts_code> --type all
# 3. 搜索网络信息
uv run scripts/search.py company <公司名称> --industry <行业>
# 4. 执行评分规则(根据 SKILL 中的打分标准)
# ... 计算 scores, screening, checklist ...
# 5. 生成并输出分析报告
Output: Display the complete stock selection scoring report in the terminal