StockFlow MCP Server

by twolven
Verified

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

Integrations

  • Hosts the StockFlow MCP server code repository, allowing users to clone and access the implementation.

  • Provides a Python-based interface for retrieving and analyzing stock market data, supporting programmatic access to stock information, historical price data, and options analysis.

StockFlow MCP 서버

Yahoo Finance를 통해 실시간 주식 데이터 및 옵션 분석을 제공하는 모델 컨텍스트 프로토콜(MCP) 서버입니다. LLM이 시장 데이터에 접근하고, 주식을 분석하고, 옵션 전략을 평가할 수 있도록 지원합니다.

특징

주식 데이터

  • 실시간 주가 및 주요 지표
  • OHLC 값을 포함한 과거 가격 데이터
  • 회사 기본 사항 및 재무 제표
  • 시장 지표 및 비율

옵션 분석

  • 완전한 옵션 체인 데이터
  • 그리스인(델타, 감마, 세타, 베가)
  • 거래량 및 미결제약정 추적
  • 옵션 전략 분석

설치

지엑스피1

용법

  1. 저장소를 복제합니다.
git clone https://github.com/twolven/mcp-stockflow.git cd mcp-stockflow
  1. 종속성 설치:
pip install -r requirements.txt
  1. Claude 구성에 다음을 추가합니다. claude-desktop-config.json 에서 mcpServers 섹션에 다음을 추가합니다.
{ "mcpServers": { "stockflow": { "command": "python", "args": ["path/to/stockflow.py"] } } }

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

Claude에 대한 사용 프롬프트

Claude와 함께 작업할 때 이 프롬프트를 사용하면 사용 가능한 도구를 이해하는 데 도움이 됩니다.

주식 시장 데이터에 접근할 수 있는 주식 흐름 도구를 활성화했습니다. 다음 세 가지 주요 기능을 사용할 수 있습니다.

  1. get_stock_data - 포괄적인 주식 정보를 얻으세요:
{ "symbol": "AAPL", "include_financials": true, # optional "include_analysis": true, # optional "include_calendar": true # optional }
  1. get_historical_data - 가격 내역 및 기술 지표 가져오기:
{ "symbol": "AAPL", "period": "1y", # 1d, 5d, 1mo, 3mo, 6mo, 1y, 2y, 5y, 10y, ytd, max "interval": "1d", # 1m, 2m, 5m, 15m, 30m, 60m, 90m, 1h, 1d, 5d, 1wk, 1mo, 3mo "prepost": false # optional - include pre/post market data }
  1. get_options_chain - 옵션 데이터 가져오기:
{ "symbol": "AAPL", "expiration_date": "2024-12-20", # optional - uses nearest date if not specified "include_greeks": true # optional }

모든 응답에는 현재 가격 데이터, 오류 처리, 포괄적인 시장 정보가 포함됩니다.

서버 실행

python stockflow.py

MCP 클라이언트와 함께 사용

from mcp import ClientSession, StdioServerParameters from mcp.client.stdio import stdio_client server_params = StdioServerParameters( command="python", args=["stockflow.py"] ) async def run(): async with stdio_client(server_params) as (read, write): async with ClientSession(read, write) as session: await session.initialize() # Get current stock data result = await session.call_tool( "get-stock-data", arguments={"symbol": "AAPL"} ) # Get options chain options = await session.call_tool( "get-options-chain", arguments={ "symbol": "AAPL", "expiration_date": "2024-12-20" } ) if __name__ == "__main__": import asyncio asyncio.run(run())

사용 가능한 도구

  1. get-stock-data
    • 현재 가격 및 거래량
    • 시가총액과 P/E 비율
    • 52주 최고가/최저가
  2. get-historical-data
    • OHLC 가격
    • 구성 가능한 기간
    • 볼륨 데이터
  3. get-options-chain
    • 콜과 풋
    • 행사 가격
    • 그리스인과 IV
    • 거래량 및 미결제약정

사용 가능한 리소스

  1. company-info://{symbol}
    • 회사 설명
    • 부문 및 산업
    • 직원 수
    • 웹사이트
  2. financials://{symbol}
    • 손익계산서
    • 대차대조표
    • 현금흐름표

프롬프트

  1. analyze-options
    • 옵션 전략 분석
    • 위험/보상 평가
    • 시장 상황 평가

요구 사항

  • 파이썬 3.12+
  • 엠씨피
  • 와이파이낸스

제한 사항

  • 데이터는 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

Yahoo Finance를 통해 실시간 주식 데이터와 옵션 분석을 제공하는 모델 컨텍스트 프로토콜 서버로, LLM이 시장 데이터에 접근하고, 주식을 분석하고, 옵션 전략을 평가할 수 있도록 지원합니다.

  1. Features
    1. Stock Data
    2. Options Analysis
  2. Installation
    1. Usage
      1. Usage Prompt for Claude
        1. Running the Server
        2. Using with MCP Client
      2. Available Tools
        1. Available Resources
          1. Prompts
            1. Requirements
              1. Limitations
                1. Contributing
                  1. License
                    1. Author
                      1. Acknowledgments
                        1. Acknowledgments
                          ID: c3yxx6ue78