Skip to main content
Glama
twolven

StockScreen MCP Server

StockScreen MCP 서버

Yahoo Finance를 통해 포괄적인 주식 스크리닝 기능을 제공하는 모델 컨텍스트 프로토콜(MCP) 서버입니다. LLM이 기술적, 펀더멘털 및 옵션 기준에 따라 주식을 스크리닝할 수 있도록 지원하며, 관심 종목 관리 및 결과 저장 기능을 지원합니다.

특징

주식 스크리닝

  • 기술 분석 스크리닝

    • 가격 및 볼륨 필터

    • 이동 평균(20, 50, 200 SMA)

    • RSI 지표

    • 평균 참 범위(ATR)

    • 추세 분석(1일, 5일, 20일 변화)

    • MA 거리 계산

  • 기본 검진

    • 시가총액 필터

    • P/E 비율 분석

    • 배당수익률 기준

    • 매출 성장 지표

    • ETF별 지표(AUM, 비용 비율)

  • 옵션 스크리닝

    • 암묵적 변동성(IV) 필터

    • 옵션 거래량 및 미결제약정

    • 풋/콜 비율 분석

    • 매수-매도 스프레드 평가

    • 수입일 근접성 확인

데이터 관리

  • 관심 목록 생성 및 관리

  • 스크리닝 결과 저장

  • 기본 기호 범주

    • 메가캡(2000억 달러 이상)

    • 대형주($100억~$2000억)

    • 중형주(20억~100억 달러)

    • 소형주(3억~20억 달러)

    • 마이크로 캡(<$300M)

    • ETF

Related MCP server: Yahoo Finance MCP for LLaMA 3.2 3B

설치

지엑스피1

용법

  1. Claude 구성에 다음을 추가합니다. claude-desktop-config.json 에서 mcpServers 섹션에 다음을 추가합니다.

{
    "mcpServers": {
        "stockscreen": {
            "command": "python",
            "args": ["path/to/stockscreen.py"]
        }
    }
}

"path/to/stockscreen.py"를 stockscreen.py 파일을 저장한 전체 경로로 바꾸세요.

사용 가능한 도구

사용 가능한 도구

  1. run_stock_screen

기술 검사 기준

{
    "screen_type": "technical",
    "criteria": {
        "min_price": float,              # Minimum stock price
        "max_price": float,              # Maximum stock price
        "min_volume": int,               # Minimum average volume
        "above_sma_200": bool,           # Price above 200-day SMA
        "above_sma_50": bool,            # Price above 50-day SMA
        "min_rsi": float,                # Minimum RSI value
        "max_rsi": float,                # Maximum RSI value
        "max_atr_pct": float,            # Maximum ATR as percentage of price
        "category": str                  # Optional: market cap category filter
    },
    "watchlist": str,                    # Optional: name of watchlist to screen
    "save_result": str                   # Optional: name to save results
}

기본 스크린 기준

{
    "screen_type": "fundamental",
    "criteria": {
        "min_market_cap": float,         # Minimum market capitalization
        "min_pe": float,                 # Minimum P/E ratio
        "max_pe": float,                 # Maximum P/E ratio
        "min_dividend": float,           # Minimum dividend yield (%)
        "min_revenue_growth": float,     # Minimum revenue growth rate
        "category": str,                 # Optional: market cap category filter
        
        # ETF-specific criteria
        "min_aum": float,                # Minimum assets under management
        "max_expense_ratio": float,      # Maximum expense ratio
        "min_volume": float              # Minimum trading volume
    },
    "watchlist": str,                    # Optional: name of watchlist to screen
    "save_result": str                   # Optional: name to save results
}

옵션 화면 기준

{
    "screen_type": "options",
    "criteria": {
        "min_iv": float,                 # Minimum implied volatility (%)
        "max_iv": float,                 # Maximum implied volatility (%)
        "min_option_volume": int,        # Minimum options volume
        "min_put_call_ratio": float,     # Minimum put/call ratio
        "max_spread": float,             # Maximum bid-ask spread (%)
        "min_days_to_earnings": int,     # Minimum days until earnings
        "max_days_to_earnings": int,     # Maximum days until earnings
        "category": str                  # Optional: market cap category filter
    },
    "watchlist": str,                    # Optional: name of watchlist to screen
    "save_result": str                   # Optional: name to save results
}

뉴스 화면 기준

{
    "screen_type": "news",
    "criteria": {
        "keywords": List[str],           # Keywords to search for in news
        "exclude_keywords": List[str],    # Keywords to exclude from results
        "min_days": int,                 # Minimum days back to search
        "max_days": int,                 # Maximum days back to search
        "management_changes": bool,       # Filter for management changes
        "require_all_keywords": bool,     # Require all keywords to match
        "category": str                  # Optional: market cap category filter
    },
    "watchlist": str,                    # Optional: name of watchlist to screen
    "save_result": str                   # Optional: name to save results
}

사용자 정의 화면 기준

{
    "screen_type": "custom",
    "criteria": {
        "category": str,                 # Optional: market cap category filter
        "technical": {
            # Any technical criteria from above
        },
        "fundamental": {
            # Any fundamental criteria from above
        },
        "options": {
            # Any options criteria from above
        },
        "news": {
            # Any news criteria from above
        }
    },
    "watchlist": str,                    # Optional: name of watchlist to screen
    "save_result": str                   # Optional: name to save results
}

카테고리 값

필터링 가능한 시가총액 범주:

  • "mega_cap": 2000억 달러 이상

  • "대형_주식": 100억~2000억 달러

  • "중형주": 20억~100억 달러

  • "소형주": 3억~20억 달러

  • "마이크로캡": <$300M

  • "etf": ETF 상품

  1. manage_watchlist

{
    "action": str,                       # Required: "create", "update", "delete", "get"
    "name": str,                         # Required: watchlist name (1-50 chars, alphanumeric with _ -)
    "symbols": List[str]                 # Required for create/update: list of stock symbols
}
  1. get_screening_result

{
    "name": str                          # Required: name of saved screening result
}

응답 형식

기술 화면 응답

{
    "screen_type": "technical",
    "criteria": dict,                    # Original criteria used
    "matches": int,                      # Number of matching stocks
    "results": [                         # List of matching stocks
        {
            "symbol": str,
            "price": float,
            "volume": float,
            "rsi": float,
            "sma_20": float,
            "sma_50": float,
            "sma_200": float,
            "atr": float,
            "atr_pct": float,
            "price_changes": {
                "1d": float,             # 1-day price change %
                "5d": float,             # 5-day price change %
                "20d": float             # 20-day price change %
            },
            "ma_distances": {
                "pct_from_20sma": float,
                "pct_from_50sma": float,
                "pct_from_200sma": float
            }
        }
    ],
    "rejected": [                        # List of stocks that didn't match
        {
            "symbol": str,
            "rejection_reasons": List[str]
        }
    ],
    "timestamp": str
}

Claude에 대한 사용 프롬프트

"주식 스크리닝 기능을 제공하는 주식 스크리닝 도구를 활성화했습니다. 세 가지 주요 기능을 사용할 수 있습니다.

  1. 다양한 기준 유형으로 재고를 스크린합니다.

    • 기술: 가격, 거래량, RSI, 이동 평균선, ATR

    • 기본: 시가총액, P/E, 배당금, 성장

    • 옵션: IV, 거래량, 수익일

    • 사용자 정의: 여러 기준 유형을 결합합니다.

  2. 관심 목록 관리:

    • 심볼 목록 생성 및 업데이트

    • 기존 관심 목록 삭제

    • 관심목록 내용 검색

  3. 저장된 검사 결과에 액세스하세요.

    • 이전 화면 결과 로드

    • 일치하는 기호 및 기준 검토

모든 기능에는 오류 처리, 세부적인 시장 데이터, 포괄적인 대응이 포함됩니다."

요구 사항

  • 파이썬 3.12+

  • MCP 서버

  • 와이파이낸스

  • 팬더

  • 넘파이

  • 비동기

제한 사항

  • Yahoo Finance에서 얻은 데이터로 지연 가능성이 있음

  • Yahoo Finance API 제한에 따른 요금 제한

  • 옵션 데이터 가용성은 시장 시간에 따라 달라집니다.

  • 일부 재무 지표가 지연되거나 사용할 수 없을 수 있습니다.

기여하다

기여를 환영합니다! 풀 리퀘스트를 제출해 주세요.

특허

이 프로젝트는 MIT 라이선스에 따라 라이선스가 부여되었습니다. 자세한 내용은 라이선스 파일을 참조하세요.

작가

토드 울븐 - ( https://github.com/tolven )

감사의 말

  • Anthropic의 MCP(Model Context Protocol)로 구축됨

  • Yahoo Finance 에서 제공하는 데이터

  • Anthropic의 Claude와 함께 사용하도록 개발됨

-
security - not tested
A
license - permissive license
-
quality - not tested

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/twolven/mcp-stockscreen'

If you have feedback or need assistance with the MCP directory API, please join our Discord server