Skip to main content
Glama
Omi MCP Server

Omi MCP Server

by fourcolors

오미 MCP 서버

대장간 배지

이 프로젝트는 Omi API와 상호 작용하기 위한 모델 컨텍스트 프로토콜(MCP) 서버를 제공합니다. 이 서버는 대화와 기억을 읽고 새로운 대화와 기억을 생성하는 도구를 제공합니다.

설정

  1. 저장소를 복제합니다

  2. npm install 로 종속성 설치

  3. 다음 변수를 사용하여 .env 파일을 만듭니다.

    지엑스피1

Related MCP server: Omi Memories MCP Server

용법

Smithery를 통해 설치

Smithery를 통해 Claude Desktop에 Omi MCP 서버를 자동으로 설치하려면:

npx -y @smithery/cli install @fourcolors/omi-mcp --client claude

서버 구축

npm run build

서버 실행

npm run start

개발 모드

핫 리로딩을 사용한 개발의 경우:

npm run dev

서버 테스트

MCP 서버와 상호 작용하기 위한 간단한 테스트 클라이언트가 포함되어 있습니다. 프로젝트를 빌드한 후 다음을 실행하세요.

npm run test

또는 직접:

./test-mcp-client.js

이렇게 하면 MCP 서버가 시작되고 사용 가능한 도구를 테스트할 수 있는 대화형 메뉴가 제공됩니다. 테스트 클라이언트는 모든 작업에 기본 테스트 사용자 ID( test-user-123 )를 사용합니다.

청소하고 재건하다

빌드 디렉토리를 정리하고 처음부터 다시 빌드하려면:

npm run rebuild

Claude와 Cursor를 사용한 구성

클로드 구성

Anthropic Console이나 API를 통해 Claude와 함께 이 MCP 서버를 사용하려면:

  1. MCP 서버를 로컬로 시작합니다.

    npm run start
  2. Claude 대화를 설정할 때 MCP 연결을 구성하세요.

    {
     "mcp_config": {
         "transports": [
             {
                 "type": "stdio",
                 "executable": {
                     "path": "/path/to/your/omi-mcp-local/dist/index.js",
                     "args": []
                 }
             }
         ]
     }
    }
  3. 클로드에게 보내는 예시 프롬프트:

    Please fetch the latest 5 conversations for user "user123" using the Omi API.
  4. Claude는 MCP를 사용하여 read_omi_conversations 도구를 실행합니다.

    {
     "id": "req-1",
     "type": "request",
     "method": "tools.read_omi_conversations",
     "params": {
         "user_id": "user123",
         "limit": 5
     }
    }

커서 구성

커서와 함께 이 MCP 서버를 사용하려면:

  1. 터미널에서 MCP 서버를 시작합니다.

    npm run start
  2. 커서에서 설정 > 확장 프로그램 > MCP 서버로 이동합니다.

  3. 다음 설정으로 새로운 MCP 서버를 추가합니다.

    • 이름: Omi API

    • URL: stdio:/path/to/your/omi-mcp-local/dist/index.js

    • 서버를 활성화하세요

  4. 이제 커서 내에서 Omi 도구를 직접 사용할 수 있습니다. 예:

    @Omi API Please fetch memories for user "user123" and summarize them.
  5. 커서는 MCP 서버와 통신하여 필요한 API 호출을 실행합니다.

사용 가능한 도구

MCP 서버는 다음과 같은 도구를 제공합니다.

read_omi_대화

선택적 필터를 사용하여 특정 사용자의 Omi 대화를 검색합니다.

매개변수:

  • user_id (문자열): 대화를 가져올 사용자 ID

  • limit (숫자, 선택 사항): 반환할 대화의 최대 수

  • offset (숫자, 선택 사항): 페이지 매김을 위해 건너뛸 대화 수

  • include_discarded (부울, 선택 사항): 삭제된 대화를 포함할지 여부

  • statuses (문자열, 선택 사항): 대화를 필터링할 상태의 쉼표로 구분된 목록

read_omi_memories

특정 사용자의 오미로부터 기억을 검색합니다.

매개변수:

  • user_id (문자열): 메모리를 가져올 사용자 ID

  • limit (숫자, 선택 사항): 반환할 최대 메모리 수

  • offset (숫자, 선택 사항): 페이지 매김을 위해 건너뛸 메모리 수

OMI 대화 생성

특정 사용자에 대한 Omi에서 새로운 대화를 만듭니다.

매개변수:

  • text (문자열): 대화의 전체 텍스트 내용

  • user_id (문자열): 대화를 생성할 사용자 ID

  • text_source (문자열): 텍스트 콘텐츠의 소스(옵션: "audio_transcript", "message", "other_text")

  • started_at (문자열, 선택 사항): 대화/이벤트가 시작된 시간(ISO 8601 형식)

  • finished_at (문자열, 선택 사항): 대화/이벤트가 종료된 시점(ISO 8601 형식)

  • language (문자열, 선택 사항): 언어 코드(기본값: "en")

  • geolocation (객체, 선택 사항): 대화에 대한 위치 데이터

    • latitude (숫자): 위도 좌표

    • longitude (숫자): 경도 좌표

  • text_source_spec (문자열, 선택 사항): 소스에 대한 추가 사양

create_omi_memories

특정 사용자를 위해 오미에서 새로운 추억을 만듭니다.

매개변수:

  • user_id (문자열): 메모리를 생성할 사용자 ID

  • text (문자열, 선택 사항): 메모리를 추출할 텍스트 콘텐츠

  • memories (배열, 선택 사항): 직접 생성할 명시적 메모리 객체의 배열

    • content (문자열): 메모리의 내용

    • tags (문자열 배열, 선택 사항): 메모리에 대한 태그

  • text_source (문자열, 선택 사항): 텍스트 콘텐츠의 소스

  • text_source_spec (문자열, 선택 사항): 소스에 대한 추가 사양

테스트

MCP 서버를 테스트하려면 제공된 테스트 클라이언트를 사용할 수 있습니다.

node test-mcp-client.js

이렇게 하면 다음 작업을 수행할 수 있는 대화형 테스트 클라이언트가 시작됩니다.

  1. 대화를 시작하세요

  2. 추억을 얻으세요

  3. 대화를 만들어 보세요

  4. 그만두다

테스트 클라이언트는 모든 작업에 기본 테스트 사용자 ID( test-user-123 )를 사용합니다.

벌채 반출

MCP 서버에는 콘솔과 로그 파일 모두에 기록하는 로깅 기능이 내장되어 있습니다. 이 기능은 서버 활동 디버깅 및 모니터링에 유용합니다.

로그 파일 위치

로그는 프로젝트 디렉터리의 logs/mcp-server.log 에 기록됩니다. 로그 파일에는 타임스탬프와 다음 항목에 대한 자세한 정보가 포함되어 있습니다.

  • 서버 시작 및 종료

  • 모든 API 요청 및 응답

  • 오류 메시지 및 스택 추적

  • Omi에 대한 API 호출

  • 요청 매개변수 및 응답 데이터

로그 보기

tail 명령을 사용하면 실시간으로 로그를 볼 수 있습니다.

tail -f logs/mcp-server.log

이를 통해 서버가 요청을 처리하고 Omi API와 상호 작용할 때 실시간 업데이트가 표시됩니다.

로그 형식

각 로그 항목은 다음 형식을 따릅니다.

[2024-03-21T12:34:56.789Z] Log message here

타임스탬프는 ISO 8601 형식이므로 이벤트를 쉽게 연관시키고 문제를 디버깅할 수 있습니다.

Available Tools

4 tools
create_omi_conversationC

Creates a new Omi conversation with text content and metadata

Inputs: text (required), text_source (required), user_id (required), finished_at, +4 more.

create_omi_memoriesB

Creates Omi memories by extracting from text or using explicit memory objects

Inputs: user_id (required), memories, text, text_source, +1 more.

read_omi_conversationsC

Retrieves user conversations from Omi with pagination and filtering options

Inputs: user_id (required), include_discarded, limit, offset, +1 more.

read_omi_memoriesB

Retrieves user memories from Omi with pagination options

Inputs: user_id (required), limit, offset.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.4/5.0

    Scored across 4 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose: create vs. read operations for two distinct resources (conversations and memories). The separation between conversations and memories is explicit, and the create/read distinction is unambiguous, leaving no room for confusion or misselection.

    Naming Consistency5/5

    All tool names follow a consistent verb_noun pattern with 'create' or 'read' as the verb and 'omi_conversations' or 'omi_memories' as the noun. The naming is perfectly uniform, using snake_case throughout, making the set highly predictable and readable.

    Tool Count4/5

    With 4 tools, the count is reasonable for a server focused on Omi conversations and memories. It covers create and read operations for both resources, which is well-scoped, though it might feel slightly thin if update or delete operations are expected in the domain, but it's not a significant issue.

    Completeness3/5

    The tool set provides create and read operations for both conversations and memories, covering basic CRUD elements. However, there are notable gaps: no update or delete tools for either resource, which could limit agent workflows if modifications or deletions are needed, making the surface incomplete for full lifecycle management.

    Maintenance

    ActivityInactive
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers