Skip to content

Commit cafbd2e

Browse files
committed
Update sqlite_database_structure.md
1 parent ba6db54 commit cafbd2e

File tree

1 file changed

+59
-49
lines changed

1 file changed

+59
-49
lines changed

docs/sqlite_database_structure.md

+59-49
Original file line numberDiff line numberDiff line change
@@ -1,69 +1,79 @@
11
Note: this documentation was generated automatically from the tasks.py code using an AI. Although we are confident in the reliability of the data displayed here, errors may occur.
22

33

4-
**activity table**
4+
**Table: activity**
55
|Column|Description|
6-
|---|---|
7-
|event_name|This field represents the type of the event. It could be one of the following: message_sent, guild_joined, application_command_used, add_reaction, or app_opened.|
8-
|day|The day the event took place, formatted as 'YYYY-MM-DD'.|
9-
|hour|The hour of the day when the event took place, in 24-hour format.|
10-
|occurence_count|Number of times the specific event happened.|
11-
|associated_channel_id|The ID of the channel where the event occurred. This will be `None` if the event does not relate to any specific channel.|
12-
|associated_guild_id|The ID of the guild where the event occurred. This will be `None` if the event does not relate to any specific guild.|
13-
|associated_user_id|The ID of the user involved in the event. This will be `None` if the event does not relate to any specific user.|
14-
|extra_field_1|Additional data about the event. The type and meaning of the data will depend on the event_name.|
15-
|extra_field_2|Additional data about the event. The type and meaning of the data will depend on the event_name.|
6+
|--|--|
7+
|event_name|Contains the type of the events occurred like message_sent, guild_joined, application_command_used, add_reaction, app_opened.|
8+
|day|The date on which the activity occurred in the format 'YYYY-MM-DD'.|
9+
|hour|The hour of the day (in 24-hour format) during which the activity occurred.|
10+
|occurrence_count|The number of times that the specific event occurred.|
11+
|associated_channel_id|The ID of the channel with which the activity is associated.|
12+
|associated_guild_id|The ID of the guild with which the activity is associated.|
13+
|associated_user_id|The ID of the user with which the activity is associated.|
14+
|extra_field_1|An additional field for storing extra data related to the event, such as emoji name, operating system, etc. depending on the event type.|
15+
|extra_field_2|Another additional field for storing extra data related to the event like whether emoji is custom or not.|
1616

17-
**dm_channels_data table**
17+
**Table: dm_channels_data**
1818
|Column|Description|
19-
|---|---|
20-
|channel_id|Unique identifier for each direct message (DM) channel.|
21-
|dm_user_id|User ID for the person involved in the DM.|
22-
|user_name|The username of the person involved in the DM.|
23-
|display_name|The display name of the person involved in the DM.|
24-
|user_avatar_url|The URL linking to the avatar of the user involved in the DM.|
25-
|total_message_count|The total number of messages exchanged in this DM.|
26-
|total_voice_channel_duration|The total duration of voice activity in this channel.|
27-
|sentiment_score|A score representing the overall sentiment in the direct channel. Higher scores indicate positive sentiment, while lower scores indicate negative sentiment.|
19+
|--|--|
20+
|channel_id|Unique identifier of the direct message (DM) channel.|
21+
|dm_user_id|Unique identifier of the user involved in the direct message conversation.|
22+
|user_name|The original discord username of the user.|
23+
|display_name|The display name of the user. (It can be changed per server).|
24+
|user_avatar_url|The URL of the avatar of the user.|
25+
|total_message_count|The total number of messages in the direct message conversation.|
26+
|total_voice_channel_duration|The total time spent by the user in voice channels associated with the conversation.|
27+
|sentiment_score|The sentiment score for the messages in the conversation.|
2828

29-
**guild_channels_data table**
29+
**Table: guild_channels_data**
3030
|Column|Description|
31-
|---|---|
32-
|channel_id|ID of the guild channel.|
33-
|guild_id|ID of the guild where the channel exists.|
31+
|--|--|
32+
|channel_id|Unique identifier of the guild channel.|
33+
|guild_id|Unique identifier of the guild.|
3434
|channel_name|The name of the guild channel.|
35-
|total_message_count|The total number of messages sent in the guild channel.|
36-
|total_voice_channel_duration|The total duration of voice chat in the guild channel.|
35+
|total_message_count|The total number of messages in the guild channel.|
36+
|total_voice_channel_duration|The total time spent by users in the voice channels of the guild channel.|
3737

38-
**guilds table**
38+
**Table: guilds**
3939
|Column|Description|
40-
|---|---|
41-
|guild_id|Unique identifier for each guild.|
40+
|--|--|
41+
|guild_id|Unique identifier of the guild.|
4242
|guild_name|The name of the guild.|
4343
|total_message_count|The total number of messages exchanged in the guild.|
4444

45-
**payments table**
45+
**Table: payments**
4646
|Column|Description|
47-
|---|---|
48-
|payment_id|Unique identifier for each payment.|
49-
|payment_date|The date the payment was made, formatted as 'YYYY-MM-DD'.|
47+
|--|--|
48+
|payment_id|Unique identifier of the payment.|
49+
|payment_date|The date when the payment was made in the format 'YYYY-MM-DD'.|
5050
|payment_amount|The amount of the payment.|
51-
|payment_currency|The currency of the payment.|
52-
|payment_description|Text describing what the payment was for.|
51+
|payment_currency|The currency in which the payment was made.|
52+
|payment_description|The description of the payment.|
5353

54-
**voice_sessions table**
54+
**Table: voice_sessions**
5555
|Column|Description|
56-
|---|---|
57-
|channel_id|The ID of the channel where the voice chat took place.|
58-
|guild_id|The ID of the guild the voice chat belonged to.|
59-
|duration_mins|The duration of the voice chat, in minutes.|
60-
|started_date|The date and time the voice chat started, presented as 'YYYY-MM-DD HH:MM:SS'.|
61-
|ended_date|The date and time the voice chat ended, presented as 'YYYY-MM-DD HH:MM:SS'.|
56+
|--|--|
57+
|channel_id|Unique ID identifier of the voice channel.|
58+
|guild_id|Unique identifier of the guild.|
59+
|duration_mins|The duration (in minutes) of the voice session.|
60+
|started_date|The date and time when the voice session started.|
61+
|ended_date|The date and time when the voice session ended.|
6262

63-
**sessions table**
63+
**Table: sessions**
6464
|Column|Description|
65-
|---|---|
66-
|started_date|The date and time the session started, formatted as 'YYYY-MM-DD HH:MM:SS'.|
67-
|ended_date|The date and time the session ended, formatted as 'YYYY-MM-DD HH:MM:SS'.|
68-
|duration_mins|The duration of the session, in minutes.|
69-
|device_os|The operating system of the device used for the session.|
65+
|--|--|
66+
|started_date|The date and time when the session started.|
67+
|ended_date|The date and time when the session ended.|
68+
|duration_mins|The duration (in minutes) of the session.|
69+
|device_os|The operating system of the device where the session was initiated.|
70+
71+
**Table: package_data**
72+
|Column|Description|
73+
|--|--|
74+
|package_id|Unique identifier of the package.|
75+
|package_version|The version of the package.|
76+
|package_owner_id|Unique identifier of the owner of the package.|
77+
|package_owner_name|Username of the owner of the package.|
78+
|package_owner_display_name|Display name of the owner of the package.|
79+
|package_owner_avatar_url|The URL of the avatar of the owner of the package.|

0 commit comments

Comments
 (0)