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
feat: add .cursorrules file for custom linting rules to enforce coding standards
docs: add extensive documentation for development, architecture, and contributing
docs: increase markdown line length limit to 300 and disable ordered list prefix rule
style: set default markdown formatter in VSCode settings
refactor(bot.py): improve task monitoring by adding intelligent stuck task detection
fix(logging.py): enhance log formatting and handle long messages with continued lines
chore: update mkdocs configuration for documentation site setup and styling
Copy file name to clipboardexpand all lines: docs/content/dev/architecture.md
+11-32
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ This document provides a high-level overview of Tux's architecture and design pr
4
4
5
5
## Structure
6
6
7
-
```
7
+
```bash
8
8
.
9
9
├── tux/
10
10
│ ├── main.py
@@ -21,40 +21,22 @@ This document provides a high-level overview of Tux's architecture and design pr
21
21
22
22
### Key Components
23
23
24
-
#### `main.py`
25
-
26
-
The main entry point for the bot.
27
-
28
-
#### `bot.py`
29
-
30
-
The main bot class.
31
-
32
-
#### `cog_loader.py`
24
+
#### `main.py` - The main entry point for the bot
33
25
34
-
The cog loader class.
26
+
#### `bot.py` - The main bot class
35
27
36
-
#### `help.py`
28
+
#### `cog_loader.py` - The cog loader class
37
29
38
-
The help command class.
30
+
#### `help.py` - The help command class
39
31
40
-
#### `cogs`
41
-
42
-
The directory for all cogs.
43
-
44
-
#### `database/`
45
-
46
-
The directory for all database controllers and client.
47
-
48
-
Prisma is our type-safe database client/ORM. Models are defined and generated automatically from `.prisma` schema files. From there, we use custom controllers to handle all logic required for each model. Controllers are defined in the `controllers` directory, and within the `__init__.py` file, we import all controllers and make them available to the rest of the bot via the `DatabaseController` class. Various commands make use of this class to handle data storage and retrieval with their respective models.
32
+
#### `cogs` - The directory for all cogs
49
33
34
+
#### `database` - The directory for all database controllers and client
50
35
51
36
#### `handlers`
52
37
53
38
The directory for various services and handlers that live "behind the scenes" of the bot.
54
39
55
-
56
-
57
-
58
40
#### `ui`
59
41
60
42
The directory for all UI components and views.
@@ -64,18 +46,15 @@ The directory for all UI components and views.
64
46
The directory for all utility functions and classes.
65
47
66
48
**Important utilities to note:**
49
+
67
50
-`logger.py` - Our custom logger that overrides the default logger with `loguru` and `rich` for better logging.
68
51
-`config.py` - Our configuration manager that handles all bot configuration and secret/environment variables.
69
52
-`constants.py` - Our constants manager that handles all constant values used throughout the bot like colors, emojis, etc.
70
53
-`checks.py` - Our custom permission system that provides decorators for command access checks.
71
54
-`flags.py` - Our custom flag system that provides a way to handle flags for command arguments.
0 commit comments