-
Notifications
You must be signed in to change notification settings - Fork 2
/
config_example.yaml
76 lines (72 loc) · 1.71 KB
/
config_example.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
REPO_PATH: "/full/path/to/repo"
VENV_PATH: "/full/path/to/repo/<virtual env dir>"
VENV_DIR: "venv" # venv .venv etc.
TEST_COMMAND: ["python", "-m", "pytest", "-q"]
AIDER_PATH: "/full/path/to/aider"
MAX_LINE_LENGTH: 100
AUTOPEP8_FIX: True
ENABLE_BLACK: False
AIDER_MODEL: "<model you want to use>"
AIDER_WEAK_MODEL: "<weak model you want to use>"
LINTER: "pylint" # Options: "pylint", "flake8", "ruff"
LINE_COUNT_MAX: 500
LINE_COUNT_MIN: 50
# Security settings
MAX_CODE_LENGTH: 50000
MAX_QUESTION_LENGTH: 1000
MAX_REQUEST_SIZE_MB: 1
MAX_MEMORY_MB: 1000
API_RATE_LIMIT: 5
# Language settings
SUPPORTED_LANGUAGES:
- python
- javascript
- java
- cpp
- csharp
- go
- rust
- typescript
- ruby
- php
LANGUAGE_MAX_LENGTHS:
default: 50000
python: 50000
javascript: 50000
java: 100000
cpp: 50000
csharp: 75000
go: 50000
rust: 50000
typescript: 50000
ruby: 50000
php: 50000
DANGEROUS_PATTERNS:
default:
- "rm -rf /" # More specific to root deletion
- "mkfs." # More specific to filesystem formatting
- "dd if=/dev/"
- "wget http" # More specific to downloading
- "curl http" # More specific to downloading
- "> /dev/sd" # More specific to device writing
- "> /proc/sys"
- "> /sys/"
- "sudo rm"
- "chmod 777" # Specific dangerous permission
- "chown -R" # Recursive ownership change
python:
- "os.system("
- "subprocess.call("
- "subprocess.run("
- "eval(input"
- "exec(input"
- "__import__('os')"
javascript:
- "eval(input"
- "new Function("
- "process.exit("
- "require('child_process')."
java:
- "Runtime.getRuntime().exec("
- "ProcessBuilder("
- "System.exit(0)" # Only block explicit exits