tradingview-mcp-server: Command for Claude Code

.claude/commands/compare-peers.md

compare-peers is a command for Claude Code from fiale-plus/tradingview-mcp-server. It costs 17 tokens per session (1,248 once invoked), scanned A, original, MIT.

A stock-comparison command that puts 2–5 companies side by side using valuation, business-quality, growth, financial-risk, performance, and technical measures.

In plain words
What is it for?
Use it to compare possible investments such as AAPL, MSFT, and GOOGL, rank them by individual measures, and see which may suit different investment styles.
Why use it?
It removes the need to collect the same figures for each company and compare them manually. Rankings and a summary make differences easier to review.

Command for Claude Code

Written for Claude Code: $ARGUMENTS substitution.

This is fiale-plus/tradingview-mcp-server's own configuration. It tells Claude Code how to work on tradingview-mcp-server itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything tradingview-mcp-server configures →

Reuse

Borrowing it

Nothing to install: this file belongs to fiale-plus/tradingview-mcp-server. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/fiale-plus/tradingview-mcp-server/main/.claude/commands/compare-peers.md
Clone the repo
git clone --depth 1 https://github.com/fiale-plus/tradingview-mcp-server

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for compare-peers

README.md
[![agentmods](https://agentmods.dev/badge/commands/fiale-plus/tradingview-mcp-server/compare-peers.svg)](https://agentmods.dev/commands/fiale-plus/tradingview-mcp-server/compare-peers)
Your own site
<a href="https://agentmods.dev/commands/fiale-plus/tradingview-mcp-server/compare-peers"><img src="https://agentmods.dev/badge/commands/fiale-plus/tradingview-mcp-server/compare-peers.svg" alt="Measured on agentmods" height="20"></a>
Per session 17 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,248 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00017 $0.01248
Opus 5 $0.00009 $0.00624
Sonnet 5 $0.00003 $0.00250
Haiku 4.5 $0.00002 $0.00125

Measured 8d ago against content hash 972122e32241, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

compare-peers scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/compare-peers.md · 86 lines

How it starts

The opening of the file, as written. The whole thing — 86 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Compare Peers

Compare 2-5 stocks side-by-side across valuation, quality, growth, and technical metrics. Ranks each stock per metric and summarizes which is best for different investment styles.

Steps:

  1. Parse symbols from $ARGUMENTS

    • Accept comma-separated or space-separated symbols: AAPL MSFT GOOGL or AAPL, MSFT, GOOGL
    • Accept 2 to 5 symbols maximum
    • If no exchange prefix is provided, try NASDAQ: then NYSE:
    • If fewer than 2 symbols are provided, ask the user for at least 2 symbols
  2. Fetch data using mcp__tradingview__lookup_symbols

    • symbols: [all normalized symbols]
    • columns:
      • name, close, market_cap_basic
      • return_on_equity, price_earnings_ttm, price_book_fq, price_sales_current
      • gross_margin_ttm, net_margin_ttm, free_cash_flow_margin_ttm
      • total_revenue_yoy_growth_ttm, earnings_per_share_diluted_yoy_growth_ttm
      • debt_to_equity, beta_1_year, dividends_yield_current
      • Perf.Y, Perf.YTD, RSI
      • sector, industry
  3. Display comparison table

    • Markdown table with metrics as rows and stock symbols as columns
    • Format:
      | Metric              | AAPL      | MSFT      | GOOGL     |
      |---------------------|-----------|-----------|-----------|
      | Price               | $185.92   | $415.30   | $175.44   |
      | Market Cap          | 2.87T     | 3.08T     | 2.19T     |
      | P/E (TTM)           | 29.8      | 35.2      | 23.1      |
      | P/B                 | 45.2      | 13.4      | 6.8       |
      | P/S                 | 7.8       | 13.1      | 5.9       |
      | ROE %               | 147.3     | 38.2      | 26.1      |
      | Gross Margin %      | 45.6      | 69.4      | 55.3      |
      | Net Margin %        | 26.4      | 35.7      | 23.5      |
      | FCF Margin %        | 27.1      | 33.2      | 21.8      |
      | Revenue Growth %    | +5.2      | +16.0     | +14.3     |
      | EPS Growth %        | +8.1      | +18.3     | +31.2     |
      | Debt/Equity         | 1.96      | 0.41      | 0.06      |
      | Beta                | 1.24      | 0.90      | 1.05      |
      | Div Yield %         | 0.55      | 0.73      | N/A       |
      | 1Y Return %         | +24.2     | +31.5     | +35.7     |
      | YTD Return %        | +8.4      | +6.2      | +12.1     |
      | RSI                 | 62        | 58        | 66        |
      
    • Bold the best value in each row (lowest P/E, highest ROE, etc.)
    • Show "N/A" for any missing data

Read the full file on GitHub · 86 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 86 lines · 17 tokens per session scan A 972122e32241

Subscribe to this mod's changes

compare-peers is a command published in the GitHub repository fiale-plus/tradingview-mcp-server (50 stars, last pushed 17d ago), licensed MIT. It adds 17 tokens to every session and 1,248 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.