Skip to main content
Glama

Orca — ATK Accessibility MCP Server

実行中のGTKアプリケーションからATK(Accessibility Toolkit)のウィジェットツリーを取得し、ARIAロール/タイプに正規化して、設定可能な宣言的セキュリティポリシーを適用し、その結果を標準的なMCPクライアント(Claude、Cursor、Windsurfなど)向けのMCPツールとして公開します。

クイックスタート

cd orca
just shell        # enter nix-shell with all dependencies
just server       # start the MCP server on stdio

または手動で:

nix-shell
PYTHONPATH=src python3 -m src

Related MCP server: blade-computer-use

アーキテクチャ

orca/
├── shell.nix                 # nix-shell environment
├── pyproject.toml            # package config
├── Justfile                  # task runner
├── docs/
│   ├── README.md             # this file
│   ├── usage.md              # client integration guide
│   ├── policy.md             # policy engine reference
│   ├── atk.md                # ATK capture internals
│   └── contribute.md         # development guide
└── src/
    ├── __init__.py
    ├── __main__.py           # entry point
    ├── atk.py                # ATK tree capture
    ├── normalize.py          # ATK→ARIA normalization
    ├── policy.py             # declarative security policy
    ├── server.py             # MCP server
    └── default_policy.yaml   # ship-default policy

MCPツール

ツール

パラメータ

説明

get_tree

なし

ポリシーでフィルタリングされた完全なARIA正規化ツリー

get_tree_for_app

app_name: str

アプリにスコープされたツリー(fnmatch glob)

get_node_info

node_id: str

obj_idによる単一ノードの検索

list_apps

なし

上位レベルのアプリオブジェクト(name、pid、role)

設定

ポリシー

ポリシーファイルは次の優先順位で読み込まれます:

  1. ~/.config/atk-mcp/policy.yaml(ユーザー上書き)

  2. src/default_policy.yaml(同梱のデフォルト)

どちらも存在しない場合、またはどちらかの解析に失敗した場合は、default_action: allowとユーザールールなしでサーバーが起動します。

ポリシーは起動時に一度だけ読み込まれます。変更を反映するにはサーバーを再起動してください。

完全なスキーマと例については、docs/policy.mdを参照してください。

Nix 環境

すべての依存関係はshell.nixで管理されます。uvもvirtualenvも不要です。

主要パッケージ:

  • python314 — ランタイム

  • python314Packages.pyatspi — ATKツリーアクセス

  • python314Packages.pygobject3 — GIイントロスペクション

  • python314Packages.mcp — MCP SDK v2

  • python314Packages.pydantic-settings — ポリシー設定

  • python314Packages.pyyaml — ポリシーのパース

  • at-spi2-core, at-spi2-atk, atk, gtk3 — ランタイムライブラリ

使用方法

Cursorで使う

~/.cursor/mcp.jsonに追加:

{
  "mcpServers": {
    "atk-accessibility": {
      "command": "nix-shell",
      "args": ["--run", "python -m src"],
      "cwd": "/path/to/orca"
    }
  }
}

Claude Desktopで使う

~/Library/Application Support/Claude/claude_desktop_config.jsonに追加:

{
  "mcpServers": {
    "atk-accessibility": {
      "command": "nix-shell",
      "args": ["--run", "python -m src"],
      "cwd": "/path/to/orca"
    }
  }
}

Windsurfで使う

プロジェクトの.mcp.jsonに追加:

{
  "mcpServers": {
    "atk-accessibility": {
      "command": "nix-shell",
      "args": ["--run", "python -m src"],
      "cwd": "/path/to/orca"
    }
  }
}

コマンドラインから(対話的なテスト)

just shell
python -m src    # runs indefinitely on stdio

生のMCPリクエストをパイプして、個々のツールをテストします:

echo '{"jsonrpc":"2.0","id":1,"method":"tools/list","params":{}}' \
  | python -m src

ポリシーエンジン

完全なリファレンスはdocs/policy.mdを参照してください。

簡単な例 — すべてのheadingノードを拒否し、textbox名をマスクします:

default_action: allow
built_in_deny:
  aria_roles:
    - "password"
  state_keywords:
    - "hidden"
    - "invisible"
rules:
  - id: deny-headings
    conditions:
      role: "heading"
    action: deny
  - id: redact-forms
    conditions:
      role: "textbox"
    action: redact
    redact_fields:
      - "name"
      - "description"

ATK キャプチャ

内部的な詳細はdocs/atk.mdを参照してください。重要なポイント:

  • gi.repository.Atspiのデスクトップルートを再帰的に走査します

  • フェイルクローズ: サブプロセス分離により、AT-SPIバスが利用できない場合にGLibのabortがサーバーをクラッシュさせるのを防ぎます

  • 各ノードはobj_idrole (int)、role_namenamedescriptionstate_setattributeschild_countindex_in_parentapp_namepidをキャプチャします

正規化

ロールマップはdocs/modify.mdを参照してください。

ATKの整数ロール(0–132)はARIAロール文字列にマッピングされます。マッピングされていないロールは、そのrole_name文字列としてパススルーされます。状態名は変換されます(例: FOCUSEDfocusedCHECKEDchecked)。

開発

開発ガイドはdocs/contribute.mdを参照してください。

just shell        # enter dev environment
just test         # run verification suite
just compile      # syntax check
just lint         # import + smoke check
just server       # start server for manual testing

制限事項

  • AT-SPI非対応のWaylandアプリ: WaylandネイティブのGTKアプリの中にはAT-SPIインターフェースを公開していないものがあります。そのようなアプリではget_tree_for_app[]を返します。想定された動作であり、バグではありません。

  • ホットリロードなし: ポリシーは起動時に一度だけ読み込まれます。

  • AT-SPIバスが必要: 実行中のアクセシビリティバス(例: at-spi-bus-launcher)がない場合、ATKモジュールは[]を正常に返します。

  • Python 3.14+: typing-extensionsへの依存はありません。

ライセンス

MIT

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.

No tool schema history has been recorded yet.

Maintenance

ActivityMaintained
ResponsivenessNo issues

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • A
    license
    Not graded
    quality
    B
    maintenance
    Enables MCP clients to control macOS via accessibility and screen recording, providing tools to list apps, observe UI, click, type, press keys, and scroll.
    MIT
  • A
    license
    Not graded
    quality
    C
    maintenance
    Enables MCP clients to control a Linux/X11 desktop like a human: see the screen, move the mouse, click UI elements via the accessibility tree, type text, and manage windows.
    MIT
  • A
    license
    A
    quality
    B
    maintenance
    Browser automation MCP server that uses a real browser to give agents eyes and hands—open pages, click, fill, screenshot, and run scripts via accessibility-tree snapshots.
    22
    398
    1
    MIT

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/sachin-sankar/orca'

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