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
**CRITICAL**: This rule ACTIVELY enforces proper file organization during all development activities.
14
+
15
+
**INTEGRATION**: File organization enforcement is integrated with our existing Hilbert Formal Consistency Validation system (`scripts/hilbert_consistency_validator.py`) and pre-commit hooks (`scripts/pre_commit_hilbert_validation.py`).
16
+
17
+
## Automatic File Organization Enforcement
18
+
19
+
### Before Creating ANY File
20
+
1. **MANDATORY Check**: Determine correct directory based on file type and purpose
21
+
2. **MANDATORY Validation**: Verify the intended location matches organizational standards
22
+
3. **MANDATORY Correction**: If location is wrong, suggest correct path and refuse to proceed
23
+
24
+
### File Organization Standards
25
+
26
+
#### Python Files (.py)
27
+
```yaml
28
+
test_*.py: "tests/[category]/"
29
+
*_test.py: "tests/[category]/"
30
+
agents/*.py: "agents/[category]/"
31
+
utils/*.py: "utils/[category]/"
32
+
scripts/*.py: "scripts/"
33
+
apps/*.py: "apps/[app_name]/"
34
+
```
35
+
36
+
#### Documentation Files (.md)
37
+
```yaml
38
+
README.md: "Project root OR module root"
39
+
docs/*.md: "docs/[category]/"
40
+
agile/*.md: "docs/agile/[subcategory]/"
41
+
architecture/*.md: "docs/architecture/"
42
+
```
43
+
44
+
#### Configuration Files
45
+
```yaml
46
+
*.toml: "Project root"
47
+
*.yaml/*.yml: "workflow/ OR templates/"
48
+
*.json: "prompts/templates/ OR monitoring/"
49
+
```
50
+
51
+
#### Rule Files (.mdc)
52
+
```yaml
53
+
*.mdc: ".cursor/rules/[category]/"
54
+
```
55
+
56
+
### Enforcement Actions
57
+
58
+
#### When File Creation is Attempted
59
+
```python
60
+
# REQUIRED: Execute this check BEFORE creating any file
0 commit comments