feat(desktop): Aivis ユーザー辞書 + 日別使用量ダッシュボード#288
Conversation
- local-db: settings.aivis_user_dictionary_uuid を追加 (migration 0061)
- main/lib/aivis/client.ts: Bearer 認証 + エラー型付きの fetch ラッパー
- TRPC: aivis サブルーターを新設 (dictionary.list/get/create/update/delete/import/export,
usage.daily/me, validateKey)。API Key 未設定や 401 を型付きで返す
- aivis-tts: 合成リクエストに user_dictionary_uuid を付与
- settings TRPC: userDictionaryUuid の get/set を追加
- UI:
- AivisDictionary: 辞書一覧カード、インライン編集ダイアログ (surface/読み/
アクセント/優先度/品詞)、新規作成ダイアログ、AivisSpeech 互換 JSON の
import/export、削除確認、適用中マーカー
- AivisUsage: 7/30 日期間タブ、3 統計カード (requests/chars/credits)、
日別バーグラフ (credits/requests/chars トグル)、日別テーブル、APIキー
別内訳、5 分キャッシュ
- AivisSettings: 辞書セレクタを Model UUID 下に追加
- settings 検索: RINGTONES_AIVIS_DICTIONARY / RINGTONES_AIVIS_USAGE を追加
|
Warning Rate limit exceeded
Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 8 minutes and 36 seconds. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (18)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 9c5343959d
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
- P2: 辞書削除の失敗時にアクティブ指定を誤って解除する問題を修正 (remove.mutate の onSuccess コールバック内で解除する) - P2: 使用量取得エラー時にゼロ埋めダッシュボードが表示されて あたかも正当な 0 使用量に見える問題を修正 (data が無い時は エラー/ローディング表示のみ、data がある時のみ panel を描画)
関連: #286 (#287 でマージ済みの Aivis 音声通知の続編)
概要
Settings > Notifications > Aivis セクションに、ユーザー辞書の管理と日別使用量ダッシュボードを追加。
ユーザー辞書
settings.aivis_user_dictionary_uuidを追加 (migration 0061)main/lib/aivis/client.ts— Bearer 認証 + エラー型 (AivisApiKeyMissingError/AivisApiError) 付きの共通 fetch ラッパーdictionary.list/get/create/update/delete/import/export+usage.daily/me+validateKeyuser_dictionary_uuidを TTS リクエストに付与 (辞書選択中のみ)surface / 読み (カタカナ検証) / アクセント型 / 優先度 0-10 / 品詞日別使用量ダッシュボード
aivis.usage.daily(startDate, endDate)— Aivis/v1/payment/usage-summaries(時間単位) をクライアント側で日別集計 + API キー別内訳を添付動作確認
スキップ