You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+7-9Lines changed: 7 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -72,21 +72,19 @@ black .
72
72
73
73
### `/listeners`
74
74
75
-
Every incoming request is routed to a "listener". Inside this directory, we group each listener based on the Slack Platform feature used, so `/listeners/events` handles incoming events, `/listeners/shortcuts` would handle incoming [Shortcuts](https://docs.slack.dev/interactivity/implementing-shortcuts/) requests, and so on.
76
-
77
-
**Note**: The `listeners/events` folder is purely educational and demonstrates alternative implementation approaches. These listeners are **not registered** and are not used in the actual application. For the working implementation, refer to `listeners/assistant.py`.
75
+
Every incoming request is routed to a "listener". This directory groups each listener based on the Slack Platform feature used, so `/listeners/events` handles incoming events, `/listeners/shortcuts` would handle incoming [Shortcuts](https://docs.slack.dev/interactivity/implementing-shortcuts/) requests, and so on.
78
76
77
+
:::info[The `listeners/events` folder is purely educational and demonstrates alternative approaches to implementation]
78
+
These listeners are **not registered** and are not used in the actual application. For the working implementation, refer to `listeners/assistant.py`.
79
79
**`/listeners/assistant`**
80
80
81
81
Configures the new Slack Assistant features, providing a dedicated side panel UI for users to interact with the AI chatbot. This module includes:
82
82
83
-
`assistant.py`
84
-
*`@assistant.thread_started` - Receives an event when users start new app thread.
85
-
*`@assistant.user_message` - Processes user messages in app threads or from the app **Chat** and **History** tab.
86
-
87
-
`llm_caller.py`
88
-
* Handles OpenAI API integration and message formatting. Includes the `call_llm()` function that sends conversation threads to OpenAI's models and converts markdown responses to Slack-compatible formatting.
83
+
`assistant.py`, which contains two listeners:
84
+
* The `@assistant.thread_started` listener receives an event when users start new app thread.
85
+
* The `@assistant.user_message` listener processes user messages in app threads or from the app **Chat** and **History** tab.
89
86
87
+
`llm_caller.py`, which handles OpenAI API integration and message formatting. It includes the `call_llm()` function that sends conversation threads to OpenAI's models and converts markdown responses to Slack-compatible formatting.
0 commit comments