跳到主要内容
    ↑↓ 选择↵ 打开esc 关闭
    中文English
    Ncastro878
    opencode-say

    Text-to-speech plugin for OpenCode - hear AI responses spoken aloud

    GitHub 星标

    0

    月装机量

    7

    近 7 天 2

    综合评分SCORE

    16.7

    生态多维模型

    最近提交

    5 个月前

    2026-03-08

    快速安装与配置

    opencode.json

    写入当前项目的 opencode.json,只对这个仓库生效。

    opencode.json

    {
      "$schema": "https://opencode.ai/config.json",
      "plugin": ["opencode-say@1.0.0"]
    }

    opencode 启动时会通过内嵌运行时自动加载 npm 依赖并缓存至本地目录,无需手动在全局环境执行安装。

    npm

    Text-to-speech plugin for OpenCode - hear AI responses spoken aloud.

    Uses macOS say command for text-to-speech. Perfect for hands-free coding with dictation software.

    Installation

    Add to your opencode.json:

    {
      "plugin": ["opencode-say"]
    }
    

    Or install globally in ~/.config/opencode/opencode.json.

    Usage

    Toggle Speech Mode

    Create a /say command by adding .opencode/command/say.md:

    ---
    description: Toggle speech mode on/off
    ---
    
    Use the `say_toggle` tool to toggle speech mode.
    

    Then type /say in OpenCode to toggle speech on/off.

    Available Tools

    The plugin exposes three tools that the AI can use:

    Tool Description
    say_toggle Toggle speech mode on/off
    say_config Configure voice, rate, and max length
    say_status Check current settings

    Configuration

    Settings are stored in .opencode/say-settings.json:

    {
      "enabled": true,
      "voice": "Samantha",
      "rate": 180,
      "maxLength": 500
    }
    
    Setting Type Default Description
    enabled boolean false Whether speech is enabled
    voice string system default macOS voice name
    rate number system default Words per minute
    maxLength number 500 Max characters before truncating

    Available Voices

    List available voices:

    say -v '?'
    

    Common high-quality voices:

    • Samantha - American female
    • Daniel - British male
    • Karen - Australian female
    • Moira - Irish female

    Requirements

    • macOS (uses the say command)
    • OpenCode v1.2.0+

    License

    MIT