@voodocs/cli 2.1.3 → 2.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +215 -38
- package/LICENSE +1 -1
- package/PRIVACY.md +10 -10
- package/README.md +39 -35
- package/USAGE.md +50 -27
- package/examples/.cursorrules +9 -9
- package/examples/instructions/.claude/instructions.md +77 -65
- package/examples/instructions/.cursorrules +9 -9
- package/examples/instructions/.windsurfrules +9 -9
- package/examples/instructions/VOODOCS_INSTRUCTIONS.md +74 -62
- package/examples/math_example.py +1 -1
- package/examples/phase2_test.py +1 -1
- package/examples/test_function_invariants.py +1 -1
- package/lib/cli/__init__.py +3 -3
- package/lib/cli/benchmark.py +3 -3
- package/lib/cli/context.py +1 -1
- package/lib/cli/fix.py +1 -1
- package/lib/cli/generate.py +60 -1
- package/lib/cli/init.py +10 -10
- package/lib/cli/instruct.py +1 -1
- package/lib/cli/validate.py +3 -3
- package/lib/darkarts/annotations/DARKARTS_SYMBOLS.md +110 -95
- package/lib/darkarts/annotations/TRANSFORMATION_EXAMPLES.md +29 -27
- package/lib/darkarts/annotations/parser.py +1 -1
- package/lib/darkarts/cli_darkarts.py +5 -5
- package/lib/darkarts/context/ai_instructions.py +12 -12
- package/lib/darkarts/context/ai_integrations.py +16 -16
- package/lib/darkarts/context/commands.py +4 -4
- package/lib/darkarts/context/errors.py +1 -1
- package/lib/darkarts/context/models.py +1 -1
- package/lib/darkarts/context/ui.py +4 -4
- package/lib/darkarts/context/yaml_utils.py +3 -3
- package/lib/darkarts/core/loader.py +1 -1
- package/lib/darkarts/documentation/__init__.py +10 -0
- package/lib/darkarts/documentation/categorizer.py +137 -0
- package/lib/darkarts/documentation/consolidator.py +303 -0
- package/lib/darkarts/exceptions.py +3 -3
- package/lib/darkarts/plugins/voodocs/ai_native_plugin.py +1 -1
- package/lib/darkarts/plugins/voodocs/annotation_validator.py +2 -2
- package/lib/darkarts/plugins/voodocs/documentation_generator.py +3 -3
- package/lib/darkarts/plugins/voodocs/html_exporter.py +4 -4
- package/lib/darkarts/plugins/voodocs/instruction_generator.py +10 -10
- package/lib/darkarts/plugins/voodocs/pdf_exporter.py +1 -1
- package/lib/darkarts/plugins/voodocs/test_generator.py +1 -1
- package/lib/darkarts/telemetry.py +5 -5
- package/lib/darkarts/validation/README.md +6 -3
- package/package.json +2 -1
- package/requirements.txt +2 -2
- package/templates/ci/github-actions.yml +64 -64
- package/templates/ci/pre-commit-hook.sh +4 -4
- package/voodocs_cli.py +1 -1
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Voodocs Instructions for Claude Code / Cline
|
|
2
2
|
|
|
3
|
-
**Project**:
|
|
4
|
-
**Generated**: Automatically by
|
|
3
|
+
**Project**: Voodocs Example Project
|
|
4
|
+
**Generated**: Automatically by Voodocs
|
|
5
5
|
**Purpose**: Guide AI assistants to document code using @voodocs annotations
|
|
6
6
|
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
## Overview
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
Voodocs is an AI-native documentation system that allows you to document code in **DarkArts language** - a mathematical and logical notation that AI naturally understands. Your annotations will be automatically translated into human-readable documentation, property-based tests, and API specifications.
|
|
12
12
|
|
|
13
13
|
**Key Benefits:**
|
|
14
|
+
|
|
14
15
|
- Document in AI's native language (mathematical notation)
|
|
15
16
|
- Automatic generation of comprehensive tests
|
|
16
17
|
- Property-based testing with Hypothesis
|
|
@@ -22,7 +23,7 @@ As an AI coding assistant, you should add `@voodocs` annotations to **every sign
|
|
|
22
23
|
|
|
23
24
|
## Core Principles
|
|
24
25
|
|
|
25
|
-
When writing code with
|
|
26
|
+
When writing code with Voodocs annotations, follow these principles:
|
|
26
27
|
|
|
27
28
|
1. **Annotate as you code** - Add `@voodocs` annotations immediately when creating functions/classes
|
|
28
29
|
2. **Be precise** - Use mathematical notation for exact specifications
|
|
@@ -43,7 +44,7 @@ complexity: "O(1)"
|
|
|
43
44
|
security_implications: ["Requires authentication", "Validates account ownership"]
|
|
44
45
|
*/
|
|
45
46
|
function withdraw(account: Account, amount: number): boolean {
|
|
46
|
-
|
|
47
|
+
// Implementation
|
|
47
48
|
}
|
|
48
49
|
```
|
|
49
50
|
|
|
@@ -55,7 +56,7 @@ class_invariants: ["this.balance >= 0", "this.transactions.length >= 0"]
|
|
|
55
56
|
state_transitions: ["PENDING → ACTIVE", "ACTIVE → SUSPENDED", "SUSPENDED → CLOSED"]
|
|
56
57
|
*/
|
|
57
58
|
class BankAccount {
|
|
58
|
-
|
|
59
|
+
// Implementation
|
|
59
60
|
}
|
|
60
61
|
```
|
|
61
62
|
|
|
@@ -63,33 +64,33 @@ class BankAccount {
|
|
|
63
64
|
|
|
64
65
|
### For Functions/Methods
|
|
65
66
|
|
|
66
|
-
| Field
|
|
67
|
-
|
|
68
|
-
| `preconditions`
|
|
69
|
-
| `postconditions`
|
|
70
|
-
| `complexity`
|
|
71
|
-
| `invariants`
|
|
72
|
-
| `error_cases`
|
|
73
|
-
| `side_effects`
|
|
74
|
-
| `security_implications` | Optional
|
|
75
|
-
| `assumptions`
|
|
67
|
+
| Field | Required | Description | Example |
|
|
68
|
+
| ----------------------- | ----------- | --------------------------------------------- | -------------------------------------------------------------- |
|
|
69
|
+
| `preconditions` | Recommended | Conditions that must be true before execution | `["x > 0", "user is authenticated"]` |
|
|
70
|
+
| `postconditions` | Recommended | Conditions guaranteed after execution | `["result > 0", "database updated"]` |
|
|
71
|
+
| `complexity` | Recommended | Time/space complexity | `"O(n log n)"` or `"O(n)"` |
|
|
72
|
+
| `invariants` | Optional | Properties that remain unchanged | `["∀ x: x ∈ original_set ⇒ x ∈ result_set"]` |
|
|
73
|
+
| `error_cases` | Optional | Error conditions and exceptions | `["x < 0 → ValueError", "file not found → FileNotFoundError"]` |
|
|
74
|
+
| `side_effects` | Optional | External changes made | `["Writes to database", "Sends email"]` |
|
|
75
|
+
| `security_implications` | Optional | Security considerations | `["Requires admin role", "Rate limited"]` |
|
|
76
|
+
| `assumptions` | Optional | Environmental assumptions | `["Database is available", "Network is stable"]` |
|
|
76
77
|
|
|
77
78
|
### For Classes
|
|
78
79
|
|
|
79
|
-
| Field
|
|
80
|
-
|
|
81
|
-
| `class_invariants`
|
|
82
|
-
| `state_transitions` | Valid state changes
|
|
83
|
-
| `thread_safety`
|
|
80
|
+
| Field | Description | Example |
|
|
81
|
+
| ------------------- | --------------------------- | -------------------------------------------------- |
|
|
82
|
+
| `class_invariants` | Properties that always hold | `["∀ item ∈ queue: item.status ∈ VALID_STATUSES"]` |
|
|
83
|
+
| `state_transitions` | Valid state changes | `["IDLE → PROCESSING", "PROCESSING → COMPLETE"]` |
|
|
84
|
+
| `thread_safety` | Concurrency safety | `"Thread-safe with mutex"` or `"Not thread-safe"` |
|
|
84
85
|
|
|
85
86
|
### For Modules
|
|
86
87
|
|
|
87
|
-
| Field
|
|
88
|
-
|
|
89
|
-
| `module_purpose` | High-level module description | `"User authentication and authorization"`
|
|
90
|
-
| `dependencies`
|
|
91
|
-
| `assumptions`
|
|
92
|
-
| `security_model` | Overall security approach
|
|
88
|
+
| Field | Description | Example |
|
|
89
|
+
| ---------------- | ----------------------------- | --------------------------------------------- |
|
|
90
|
+
| `module_purpose` | High-level module description | `"User authentication and authorization"` |
|
|
91
|
+
| `dependencies` | External dependencies | `["@supabase/supabase-js", "bcrypt"]` |
|
|
92
|
+
| `assumptions` | Module-level assumptions | `["Database schema v2.0", "Redis available"]` |
|
|
93
|
+
| `security_model` | Overall security approach | `"Defense in depth - fails closed"` |
|
|
93
94
|
|
|
94
95
|
## DarkArts Language Guide
|
|
95
96
|
|
|
@@ -97,49 +98,49 @@ DarkArts is a mathematical notation language for precise specifications. Use the
|
|
|
97
98
|
|
|
98
99
|
### Logical Operators
|
|
99
100
|
|
|
100
|
-
| Symbol | Meaning
|
|
101
|
-
|
|
102
|
-
| `∧`
|
|
103
|
-
| `∨`
|
|
104
|
-
| `¬`
|
|
105
|
-
| `⇒`
|
|
106
|
-
| `⇔`
|
|
101
|
+
| Symbol | Meaning | Example |
|
|
102
|
+
| ------ | -------------- | ------------------------------ |
|
|
103
|
+
| `∧` | AND | `x > 0 ∧ y > 0` |
|
|
104
|
+
| `∨` | OR | `x = 0 ∨ y = 0` |
|
|
105
|
+
| `¬` | NOT | `¬(x < 0)` |
|
|
106
|
+
| `⇒` | IMPLIES | `x > 0 ⇒ result > 0` |
|
|
107
|
+
| `⇔` | IF AND ONLY IF | `result = true ⇔ user.isAdmin` |
|
|
107
108
|
|
|
108
109
|
### Quantifiers
|
|
109
110
|
|
|
110
|
-
| Symbol | Meaning
|
|
111
|
-
|
|
112
|
-
| `∀`
|
|
113
|
-
| `∃`
|
|
111
|
+
| Symbol | Meaning | Example |
|
|
112
|
+
| ------ | ------------ | ------------------------- |
|
|
113
|
+
| `∀` | FOR ALL | `∀ x ∈ items: x > 0` |
|
|
114
|
+
| `∃` | THERE EXISTS | `∃ x ∈ items: x = target` |
|
|
114
115
|
|
|
115
116
|
### Set Operations
|
|
116
117
|
|
|
117
|
-
| Symbol | Meaning
|
|
118
|
-
|
|
119
|
-
| `∈`
|
|
120
|
-
| `∉`
|
|
121
|
-
| `⊆`
|
|
122
|
-
| `∪`
|
|
123
|
-
| `∩`
|
|
118
|
+
| Symbol | Meaning | Example |
|
|
119
|
+
| ------ | --------------- | ---------------------- |
|
|
120
|
+
| `∈` | IN / ELEMENT OF | `x ∈ valid_values` |
|
|
121
|
+
| `∉` | NOT IN | `x ∉ blacklist` |
|
|
122
|
+
| `⊆` | SUBSET OF | `result ⊆ input` |
|
|
123
|
+
| `∪` | UNION | `result = set1 ∪ set2` |
|
|
124
|
+
| `∩` | INTERSECTION | `common = set1 ∩ set2` |
|
|
124
125
|
|
|
125
126
|
### Comparisons
|
|
126
127
|
|
|
127
|
-
| Symbol | Meaning
|
|
128
|
-
|
|
129
|
-
| `≥`
|
|
130
|
-
| `≤`
|
|
131
|
-
| `≠`
|
|
132
|
-
| `≈`
|
|
128
|
+
| Symbol | Meaning | Example |
|
|
129
|
+
| ------ | --------------------- | ------------------- |
|
|
130
|
+
| `≥` | GREATER THAN OR EQUAL | `x ≥ 0` |
|
|
131
|
+
| `≤` | LESS THAN OR EQUAL | `x ≤ 100` |
|
|
132
|
+
| `≠` | NOT EQUAL | `x ≠ 0` |
|
|
133
|
+
| `≈` | APPROXIMATELY EQUAL | `result ≈ expected` |
|
|
133
134
|
|
|
134
135
|
### Number Sets
|
|
135
136
|
|
|
136
|
-
| Symbol | Meaning
|
|
137
|
-
|
|
138
|
-
| `ℕ`
|
|
139
|
-
| `ℤ`
|
|
140
|
-
| `ℝ`
|
|
137
|
+
| Symbol | Meaning | Example |
|
|
138
|
+
| ------ | ------------------------------ | ------- |
|
|
139
|
+
| `ℕ` | Natural numbers (0, 1, 2, ...) | `n ∈ ℕ` |
|
|
140
|
+
| `ℤ` | Integers (..., -1, 0, 1, ...) | `x ∈ ℤ` |
|
|
141
|
+
| `ℝ` | Real numbers | `x ∈ ℝ` |
|
|
141
142
|
|
|
142
|
-
**Tip**: You can use plain English too!
|
|
143
|
+
**Tip**: You can use plain English too! Voodocs understands both mathematical notation and natural language. Mix them for clarity.
|
|
143
144
|
|
|
144
145
|
## Examples
|
|
145
146
|
|
|
@@ -172,10 +173,10 @@ side_effects: [
|
|
|
172
173
|
complexity: "O(1)"
|
|
173
174
|
*/
|
|
174
175
|
async function transferMoney(
|
|
175
|
-
|
|
176
|
-
|
|
176
|
+
request: Request,
|
|
177
|
+
response: Response
|
|
177
178
|
): Promise<void> {
|
|
178
|
-
|
|
179
|
+
// Implementation
|
|
179
180
|
}
|
|
180
181
|
```
|
|
181
182
|
|
|
@@ -198,7 +199,7 @@ assumptions: [
|
|
|
198
199
|
complexity: "O(n) where n = props.items.length"
|
|
199
200
|
*/
|
|
200
201
|
function ItemList({ items, onSelect }: ItemListProps) {
|
|
201
|
-
|
|
202
|
+
// Implementation
|
|
202
203
|
}
|
|
203
204
|
```
|
|
204
205
|
|
|
@@ -249,7 +250,7 @@ complexity: "O(1)"
|
|
|
249
250
|
"""
|
|
250
251
|
```
|
|
251
252
|
|
|
252
|
-
|
|
253
|
+
Voodocs generates:
|
|
253
254
|
|
|
254
255
|
```python
|
|
255
256
|
# Generated test
|
|
@@ -267,6 +268,7 @@ def test_property_based_add(x, y):
|
|
|
267
268
|
### 1. Be Specific with Preconditions
|
|
268
269
|
|
|
269
270
|
**Good:**
|
|
271
|
+
|
|
270
272
|
```python
|
|
271
273
|
preconditions: [
|
|
272
274
|
"amount > 0",
|
|
@@ -276,6 +278,7 @@ preconditions: [
|
|
|
276
278
|
```
|
|
277
279
|
|
|
278
280
|
**Avoid:**
|
|
281
|
+
|
|
279
282
|
```python
|
|
280
283
|
preconditions: ["valid input"] # Too vague
|
|
281
284
|
```
|
|
@@ -283,6 +286,7 @@ preconditions: ["valid input"] # Too vague
|
|
|
283
286
|
### 2. Use Mathematical Notation for Precision
|
|
284
287
|
|
|
285
288
|
**Good:**
|
|
289
|
+
|
|
286
290
|
```python
|
|
287
291
|
postconditions: [
|
|
288
292
|
"∀ x ∈ result: x ∈ input", # All results are from input
|
|
@@ -291,6 +295,7 @@ postconditions: [
|
|
|
291
295
|
```
|
|
292
296
|
|
|
293
297
|
**Avoid:**
|
|
298
|
+
|
|
294
299
|
```python
|
|
295
300
|
postconditions: ["returns filtered list"] # Imprecise
|
|
296
301
|
```
|
|
@@ -298,18 +303,21 @@ postconditions: ["returns filtered list"] # Imprecise
|
|
|
298
303
|
### 3. Always Specify Complexity
|
|
299
304
|
|
|
300
305
|
**Good:**
|
|
306
|
+
|
|
301
307
|
```python
|
|
302
308
|
complexity: "O(n log n)"
|
|
303
309
|
```
|
|
304
310
|
|
|
305
311
|
**Also Good:**
|
|
312
|
+
|
|
306
313
|
```python
|
|
307
|
-
complexity: "O(n)" #
|
|
314
|
+
complexity: "O(n)" # Voodocs infers space as O(1)
|
|
308
315
|
```
|
|
309
316
|
|
|
310
317
|
### 4. Document Security Implications
|
|
311
318
|
|
|
312
319
|
**Good:**
|
|
320
|
+
|
|
313
321
|
```python
|
|
314
322
|
security_implications: [
|
|
315
323
|
"Requires admin role",
|
|
@@ -321,6 +329,7 @@ security_implications: [
|
|
|
321
329
|
### 5. Specify Error Cases
|
|
322
330
|
|
|
323
331
|
**Good:**
|
|
332
|
+
|
|
324
333
|
```python
|
|
325
334
|
error_cases: [
|
|
326
335
|
"amount <= 0 → ValueError",
|
|
@@ -332,6 +341,7 @@ error_cases: [
|
|
|
332
341
|
### 6. Use Invariants for Loops and Recursion
|
|
333
342
|
|
|
334
343
|
**Good:**
|
|
344
|
+
|
|
335
345
|
```python
|
|
336
346
|
invariants: [
|
|
337
347
|
"∀ iteration: 0 <= i < len(arr)",
|
|
@@ -342,6 +352,7 @@ invariants: [
|
|
|
342
352
|
### 7. Document Side Effects
|
|
343
353
|
|
|
344
354
|
**Good:**
|
|
355
|
+
|
|
345
356
|
```python
|
|
346
357
|
side_effects: [
|
|
347
358
|
"Writes to database",
|
|
@@ -351,6 +362,7 @@ side_effects: [
|
|
|
351
362
|
```
|
|
352
363
|
|
|
353
364
|
**Avoid:**
|
|
365
|
+
|
|
354
366
|
```python
|
|
355
367
|
side_effects: ["Does stuff"] # Too vague
|
|
356
368
|
```
|
|
@@ -369,4 +381,4 @@ side_effects: ["Does stuff"] # Too vague
|
|
|
369
381
|
|
|
370
382
|
By documenting in DarkArts language, you're not just writing comments - you're creating a **formal specification** that generates tests, documentation, and API specs automatically.
|
|
371
383
|
|
|
372
|
-
**Generated by
|
|
384
|
+
**Generated by Voodocs** - AI-native documentation for modern development.
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Voodocs Instructions for Cursor
|
|
2
2
|
|
|
3
|
-
**Project**:
|
|
4
|
-
**Generated**: Automatically by
|
|
3
|
+
**Project**: Voodocs Example Project
|
|
4
|
+
**Generated**: Automatically by Voodocs
|
|
5
5
|
**Purpose**: Guide AI assistants to document code using @voodocs annotations
|
|
6
6
|
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
## Overview
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
Voodocs is an AI-native documentation system that allows you to document code in **DarkArts language** - a mathematical and logical notation that AI naturally understands. Your annotations will be automatically translated into human-readable documentation, property-based tests, and API specifications.
|
|
12
12
|
|
|
13
13
|
**Key Benefits:**
|
|
14
14
|
- Document in AI's native language (mathematical notation)
|
|
@@ -22,7 +22,7 @@ As an AI coding assistant, you should add `@voodocs` annotations to **every sign
|
|
|
22
22
|
|
|
23
23
|
## Core Principles
|
|
24
24
|
|
|
25
|
-
When writing code with
|
|
25
|
+
When writing code with Voodocs annotations, follow these principles:
|
|
26
26
|
|
|
27
27
|
1. **Annotate as you code** - Add `@voodocs` annotations immediately when creating functions/classes
|
|
28
28
|
2. **Be precise** - Use mathematical notation for exact specifications
|
|
@@ -137,7 +137,7 @@ DarkArts is a mathematical notation language for precise specifications. Use the
|
|
|
137
137
|
| `ℤ` | Integers (..., -1, 0, 1, ...) | `x ∈ ℤ` |
|
|
138
138
|
| `ℝ` | Real numbers | `x ∈ ℝ` |
|
|
139
139
|
|
|
140
|
-
**Tip**: You can use plain English too!
|
|
140
|
+
**Tip**: You can use plain English too! Voodocs understands both mathematical notation and natural language. Mix them for clarity.
|
|
141
141
|
|
|
142
142
|
## Examples
|
|
143
143
|
|
|
@@ -314,7 +314,7 @@ complexity: "O(1)"
|
|
|
314
314
|
"""
|
|
315
315
|
```
|
|
316
316
|
|
|
317
|
-
|
|
317
|
+
Voodocs generates:
|
|
318
318
|
|
|
319
319
|
```python
|
|
320
320
|
# Generated test
|
|
@@ -369,7 +369,7 @@ complexity: "O(n log n)"
|
|
|
369
369
|
|
|
370
370
|
**Also Good:**
|
|
371
371
|
```python
|
|
372
|
-
complexity: "O(n)" #
|
|
372
|
+
complexity: "O(n)" # Voodocs infers space as O(1)
|
|
373
373
|
```
|
|
374
374
|
|
|
375
375
|
### 4. Document Security Implications
|
|
@@ -434,4 +434,4 @@ side_effects: ["Does stuff"] # Too vague
|
|
|
434
434
|
|
|
435
435
|
By documenting in DarkArts language, you're not just writing comments - you're creating a **formal specification** that generates tests, documentation, and API specs automatically.
|
|
436
436
|
|
|
437
|
-
**Generated by
|
|
437
|
+
**Generated by Voodocs** - AI-native documentation for modern development.
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Voodocs Instructions for Windsurf
|
|
2
2
|
|
|
3
|
-
**Project**:
|
|
4
|
-
**Generated**: Automatically by
|
|
3
|
+
**Project**: Voodocs Example Project
|
|
4
|
+
**Generated**: Automatically by Voodocs
|
|
5
5
|
**Purpose**: Guide AI assistants to document code using @voodocs annotations
|
|
6
6
|
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
## Overview
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
Voodocs is an AI-native documentation system that allows you to document code in **DarkArts language** - a mathematical and logical notation that AI naturally understands. Your annotations will be automatically translated into human-readable documentation, property-based tests, and API specifications.
|
|
12
12
|
|
|
13
13
|
**Key Benefits:**
|
|
14
14
|
- Document in AI's native language (mathematical notation)
|
|
@@ -22,7 +22,7 @@ As an AI coding assistant, you should add `@voodocs` annotations to **every sign
|
|
|
22
22
|
|
|
23
23
|
## Core Principles
|
|
24
24
|
|
|
25
|
-
When writing code with
|
|
25
|
+
When writing code with Voodocs annotations, follow these principles:
|
|
26
26
|
|
|
27
27
|
1. **Annotate as you code** - Add `@voodocs` annotations immediately when creating functions/classes
|
|
28
28
|
2. **Be precise** - Use mathematical notation for exact specifications
|
|
@@ -137,7 +137,7 @@ DarkArts is a mathematical notation language for precise specifications. Use the
|
|
|
137
137
|
| `ℤ` | Integers (..., -1, 0, 1, ...) | `x ∈ ℤ` |
|
|
138
138
|
| `ℝ` | Real numbers | `x ∈ ℝ` |
|
|
139
139
|
|
|
140
|
-
**Tip**: You can use plain English too!
|
|
140
|
+
**Tip**: You can use plain English too! Voodocs understands both mathematical notation and natural language. Mix them for clarity.
|
|
141
141
|
|
|
142
142
|
## Examples
|
|
143
143
|
|
|
@@ -314,7 +314,7 @@ complexity: "O(1)"
|
|
|
314
314
|
"""
|
|
315
315
|
```
|
|
316
316
|
|
|
317
|
-
|
|
317
|
+
Voodocs generates:
|
|
318
318
|
|
|
319
319
|
```python
|
|
320
320
|
# Generated test
|
|
@@ -369,7 +369,7 @@ complexity: "O(n log n)"
|
|
|
369
369
|
|
|
370
370
|
**Also Good:**
|
|
371
371
|
```python
|
|
372
|
-
complexity: "O(n)" #
|
|
372
|
+
complexity: "O(n)" # Voodocs infers space as O(1)
|
|
373
373
|
```
|
|
374
374
|
|
|
375
375
|
### 4. Document Security Implications
|
|
@@ -434,4 +434,4 @@ side_effects: ["Does stuff"] # Too vague
|
|
|
434
434
|
|
|
435
435
|
By documenting in DarkArts language, you're not just writing comments - you're creating a **formal specification** that generates tests, documentation, and API specs automatically.
|
|
436
436
|
|
|
437
|
-
**Generated by
|
|
437
|
+
**Generated by Voodocs** - AI-native documentation for modern development.
|