0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Slackボットによる知識データの定期投稿と質問応答の自動化

Posted at

1. はじめに

Slackを活用した業務効率化の方法として、知識データの定期投稿と質問応答を自動化するSlackボットを開発しました。本記事では、その目的や実装方法を詳しく解説します。


2. 目的

(1) 知識データの定期投稿

  • 会社の利用手引きやマニュアル、業務ルールを定期的にSlackへ投稿
  • 現在はランダム投稿 だが、将来的には時間に応じた投稿も検討

(2) 質問応答システム

  • Slackボットにメンションすることで、即時に知識データを検索
  • RAG(Retrieval-Augmented Generation)を活用し、適切な回答を生成

3. Slackボットのフロー

このSlackボットは、次のような流れで動作します。

image.png

  1. ユーザーがボットに質問
  2. SlackボットがRAGシステムを使い、回答を検索
  3. 検索結果をもとに、適切な回答を生成して返信
  4. ボットが定期的にSlackチャンネルに知識データを投稿

4. 知識データの定期投稿

(1) 現在の仕組み

  • Cloud Scheduler + Cloud Run を活用し、ランダムで知識データを投稿
  • 投稿データはCloud Shell内のdocxファイルやCSVで管理

(2) 改善の方向性

  • 時間に応じた投稿(例:朝は業務開始の注意事項、午後は研修資料など)
  • 特定のトピックごとの投稿スケジュールを設定

5. 質問応答システム

(1) 現在の実装

  • Slack API + Cloud Run でボットを動作
  • RAG検索(コサイン類似度) を使用して適切な知識データを取得
  • Gemini 2.0 を活用し、ユーザーに分かりやすい回答を生成

(2) 実際のSlackでのやり取り

image.png


6. 今後の展望

  • BigQuery導入によるデータ管理強化
  • SlackのInteractive Components活用
  • 投稿スケジュール最適化(曜日・時間に応じた知識データの分類)

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?