v0.5.0

v0.5.0 Release Notes

Released


v0.4.3 -> v0.5.0

Summary


Consolidates every platform adapter under a single core/ tree, changing all import paths. Voice sending drops its built-in text-to-speech dependency and now uploads an audio file the caller already produced. Documentation and licensing are refreshed alongside.
翻譯
將全部平台 adapter 整合進單一 core/ 目錄樹,所有 import path 隨之變更。語音發送移除內建文字轉語音相依,改為上傳呼叫端已備妥的音訊檔。文件與授權同步更新。

⚠️ Breaking Changes


Platform packages moved under core/


Before:
  1. import (
  2. "github.com/pardnchiu/go-bot/telegram"
  3. "github.com/pardnchiu/go-bot/discord"
  4. "github.com/pardnchiu/go-bot/line"
  5. )

After:
  1. import (
  2. "github.com/pardnchiu/go-bot/core/telegram"
  3. "github.com/pardnchiu/go-bot/core/discord"
  4. "github.com/pardnchiu/go-bot/core/line"
  5. )

Migration:
  1. go get github.com/pardnchiu/go-bot@v0.5.0
  2. # then prefix every platform import with core/

翻譯
平台套件的 import path 全部改掛 core/ 前綴,需同步更新既有引用。

tts package removed; SendVoice takes a file path


Before:
  1. telegram.SendVoice(ctx, chatID, text, apiKey)
  2. discord.SendVoice(ctx, channelID, replyTo, text, apiKey)

After:
  1. telegram.SendVoice(ctx, chatID, "./voice.ogg")
  2. discord.SendVoice(ctx, channelID, replyTo, "./voice.ogg")

Migration:
  1. // Produce the OGG/OPUS file with your own synthesizer, then upload it.
  2. path := synthesize(ctx, text)
  3. bot.SendVoice(ctx, chatID, path)

The trailing caption ...string parameter silently absorbs the old apiKey argument, so unmigrated call sites still compile while uploading the prompt text as a file path. Audit every SendVoice call by hand rather than relying on the compiler.
翻譯
tts 套件已移除,SendVoice 改為接受既有音訊檔路徑;文字轉語音由呼叫端自行完成。 注意尾端 caption ...string 會吞掉舊的 apiKey 參數,未遷移的呼叫點仍可編譯但語意錯誤,需逐處人工檢查。

Changes


BREAKING


  • Relocate Telegram, Discord, and LINE packages under core/ (@pardnchiu) [52eadee]
  • Remove the tts package and reduce SendVoice to a file-path upload (@pardnchiu) [52eadee, 5489b26]

翻譯
  • 將 Telegram、Discord、LINE 套件移至 core/
  • 移除 tts 套件,SendVoice 簡化為檔案路徑上傳


ADD


  • Add MIT license (@pardnchiu) [a9e88eb]

翻譯
  • 新增 MIT license


DOC


  • Regenerate bilingual documentation and realign it with the text-to-speech-free API surface (@pardnchiu) [52eadee, a9e88eb, 2554f38, 91b6486]

翻譯
  • 重新生成雙語文件,並對齊移除文字轉語音後的 API 介面


Scope


  • core/telegram/, core/discord/, core/line/ — BREAKING
  • core/tts/ — BREAKING, REMOVE
  • doc/ — DOC
  • README.md, LICENSE — DOC, ADD
  • .gitignore — CHORE



Generated by SKILL