Ollama MCP Server

local-only server

The server can only run on the client’s local machine because it depends on local resources.

Integrations

  • Provides access to Ollama's local LLM models through a Model Context Protocol server, allowing listing, pulling, and chatting with Ollama models

Ollama MCP 서버

Ollama의 로컬 LLM 모델과 Claude Desktop과 같은 MCP 호환 애플리케이션 간의 원활한 통합을 구현하는 Ollama용 MCP(Model Context Protocol) 서버입니다.

특징

  • 사용 가능한 Ollama 모델 목록
  • Ollama에서 새로운 모델 가져오기
  • Ollama의 채팅 API를 사용하여 모델과 채팅하세요
  • 자세한 모델 정보를 얻으세요
  • 자동 포트 관리
  • 환경 변수 구성

필수 조건

  • Node.js(v16 이상)
  • 엔피엠
  • Ollama가 로컬에 설치 및 실행됨

설치

Smithery를 통해 설치

Smithery를 통해 Claude Desktop에 Ollama MCP Server를 자동으로 설치하는 방법:

지엑스피1

수동 설치

npm을 통해 전역적으로 설치:

npm install -g @rawveg/ollama-mcp

다른 MCP 애플리케이션에 설치

다른 MCP 호환 애플리케이션(예: Cline 또는 Claude Desktop)에 Ollama MCP 서버를 설치하려면 애플리케이션의 MCP 설정 파일에 다음 구성을 추가하세요.

{ "mcpServers": { "@rawveg/ollama-mcp": { "command": "npx", "args": [ "-y", "@rawveg/ollama-mcp" ] } } }

설정 파일 위치는 응용 프로그램마다 다릅니다.

  • Claude Desktop: Claude 앱 데이터 디렉터리의 claude_desktop_config.json
  • Cline: VS Code 글로벌 저장소의 cline_mcp_settings.json

용법

서버 시작

간단히 실행하세요:

ollama-mcp

서버는 기본적으로 3456 포트에서 시작됩니다. PORT 환경 변수를 사용하여 다른 포트를 지정할 수 있습니다.

PORT=3457 ollama-mcp

환경 변수

  • PORT : 서버 포트(기본값: 3456). 직접 실행 시와 Smithery 설치 시 모두 사용 가능합니다.
    # When running directly PORT=3457 ollama-mcp # When installing via Smithery PORT=3457 npx -y @smithery/cli install @rawveg/ollama-mcp --client claude
  • OLLAMA_API : Ollama API 엔드포인트(기본값: http://localhost:11434 )

API 엔드포인트

  • GET /models - 사용 가능한 모델 나열
  • POST /models/pull - 새 모델 가져오기
  • POST /chat - 모델과 채팅
  • GET /models/:name - 모델 세부 정보 가져오기

개발

  1. 저장소를 복제합니다.
git clone https://github.com/rawveg/ollama-mcp.git cd ollama-mcp
  1. 종속성 설치:
npm install
  1. 프로젝트를 빌드하세요:
npm run build
  1. 서버를 시작합니다:
npm start

기여하다

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

특허

MIT

관련된

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

Ollama의 로컬 LLM 모델과 MCP 호환 애플리케이션 간의 원활한 통합을 가능하게 하여 모델 관리와 채팅 상호 작용을 지원합니다.

  1. Features
    1. Prerequisites
      1. Installation
        1. Installing via Smithery
        2. Manual Installation
        3. Installing in Other MCP Applications
      2. Usage
        1. Starting the Server
        2. Environment Variables
        3. API Endpoints
      3. Development
        1. Contributing
          1. License
            1. Related
              ID: n798ehuw4c