@voodocs/cli 0.4.2 → 1.0.0
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 +312 -0
- package/lib/cli/__init__.py +53 -0
- package/lib/cli/benchmark.py +311 -0
- package/lib/cli/fix.py +244 -0
- package/lib/cli/generate.py +310 -0
- package/lib/cli/test_cli.py +215 -0
- package/lib/cli/validate.py +364 -0
- package/lib/darkarts/__init__.py +11 -5
- package/lib/darkarts/annotations/__init__.py +11 -3
- package/lib/darkarts/annotations/darkarts_parser.py +1 -1
- package/lib/darkarts/annotations/types.py +16 -3
- package/lib/darkarts/cli_darkarts.py +1 -1
- package/lib/darkarts/context/__init__.py +11 -3
- package/lib/darkarts/context/ai_integrations.py +7 -21
- package/lib/darkarts/context/commands.py +1 -1
- package/lib/darkarts/context/diagram.py +8 -22
- package/lib/darkarts/context/models.py +7 -22
- package/lib/darkarts/context/module_utils.py +1 -1
- package/lib/darkarts/context/ui.py +1 -1
- package/lib/darkarts/context/validation.py +1 -1
- package/lib/darkarts/context/yaml_utils.py +8 -23
- package/lib/darkarts/core/__init__.py +12 -2
- package/lib/darkarts/core/interface.py +16 -2
- package/lib/darkarts/core/loader.py +17 -2
- package/lib/darkarts/core/plugin.py +16 -3
- package/lib/darkarts/core/registry.py +17 -2
- package/lib/darkarts/exceptions.py +17 -3
- package/lib/darkarts/plugins/voodocs/__init__.py +12 -2
- package/lib/darkarts/plugins/voodocs/ai_native_plugin.py +16 -5
- package/lib/darkarts/plugins/voodocs/annotation_validator.py +16 -3
- package/lib/darkarts/plugins/voodocs/api_spec_generator.py +16 -3
- package/lib/darkarts/plugins/voodocs/documentation_generator.py +16 -3
- package/lib/darkarts/plugins/voodocs/html_exporter.py +16 -3
- package/lib/darkarts/plugins/voodocs/instruction_generator.py +1 -1
- package/lib/darkarts/plugins/voodocs/pdf_exporter.py +16 -3
- package/lib/darkarts/plugins/voodocs/test_generator.py +16 -3
- package/lib/darkarts/telemetry.py +16 -3
- package/lib/darkarts/validation/README.md +147 -0
- package/lib/darkarts/validation/__init__.py +91 -0
- package/lib/darkarts/validation/autofix.py +297 -0
- package/lib/darkarts/validation/benchmark.py +426 -0
- package/lib/darkarts/validation/benchmark_wrapper.py +22 -0
- package/lib/darkarts/validation/config.py +257 -0
- package/lib/darkarts/validation/performance.py +412 -0
- package/lib/darkarts/validation/performance_wrapper.py +37 -0
- package/lib/darkarts/validation/semantic.py +461 -0
- package/lib/darkarts/validation/semantic_wrapper.py +77 -0
- package/lib/darkarts/validation/test_validation.py +160 -0
- package/lib/darkarts/validation/types.py +97 -0
- package/lib/darkarts/validation/watch.py +239 -0
- package/package.json +19 -6
- package/voodocs_cli.py +28 -0
- package/cli.py +0 -1646
- package/lib/darkarts/cli.py +0 -128
|
@@ -1,24 +1,10 @@
|
|
|
1
|
-
"""@
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
"AI config directories follow standard conventions (.claude/skills/, .cursor/rules/, etc.)",
|
|
9
|
-
"Project root is current working directory",
|
|
10
|
-
"File system allows directory creation",
|
|
11
|
-
"UTF-8 encoding is supported"
|
|
12
|
-
]
|
|
13
|
-
invariants: [
|
|
14
|
-
"All generated configs must be valid for their respective AIs",
|
|
15
|
-
"Detection must not modify any files",
|
|
16
|
-
"Generated content must be UTF-8 encoded",
|
|
17
|
-
"File paths must use forward slashes for cross-platform compatibility",
|
|
18
|
-
"Each AI integration must return Dict[str, str] mapping paths to content"
|
|
19
|
-
]
|
|
20
|
-
security_model: "Read-only detection, write only when explicitly called by user commands"
|
|
21
|
-
performance_model: "O(1) for detection, O(k) for generation where k=number of AI assistants"
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢ai-integrations:context.ai-native
|
|
3
|
+
∂{pathlib,typing}
|
|
4
|
+
⚠{ai-dirs:standard-conventions,cwd:project-root,fs:writable,encoding:utf8}
|
|
5
|
+
⊨{∀config→valid-for-ai,∀detect→¬modify-files,∀content:utf8,∀path:forward-slash,∀integration→Dict[str,str]}
|
|
6
|
+
🔒{read-only:detect,write:explicit-user-command}
|
|
7
|
+
⚡{O(n²):detect-with-analysis,O(k):generate|k=ai-count}
|
|
22
8
|
|
|
23
9
|
AI-specific integration templates for VooDocs Context System.
|
|
24
10
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
⚠{.voodocs.context∈root,git:available,py≥3.11,cwd=root}
|
|
5
5
|
⊨{ctx:yaml,v∈semver,exit∈{0,1},∀update→v++,files:utf8}
|
|
6
6
|
🔒{read:ctx,write⊳confirm}
|
|
7
|
-
⚡{O(
|
|
7
|
+
⚡{O(n³):typical-nested-loops,worst-case:O(2^n):recursion-detected|32-loops,depth=3}
|
|
8
8
|
|
|
9
9
|
Context System Commands
|
|
10
10
|
|
|
@@ -1,28 +1,14 @@
|
|
|
1
|
-
"""@
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
assumptions: [
|
|
9
|
-
"Context file contains architecture.modules section",
|
|
10
|
-
"manus-render-diagram utility is available for PNG rendering",
|
|
11
|
-
"Output directory is writable",
|
|
12
|
-
"Mermaid/D2 syntax is valid"
|
|
13
|
-
]
|
|
14
|
-
invariants: [
|
|
15
|
-
"Generated diagrams must be valid Mermaid or D2 syntax",
|
|
16
|
-
"Module names must be sanitized for diagram syntax",
|
|
17
|
-
"Diagram generation must not modify context file",
|
|
18
|
-
"PNG rendering is optional and fails gracefully if utility unavailable"
|
|
19
|
-
]
|
|
20
|
-
security_model: "Read context file, write diagram files to user-specified paths"
|
|
21
|
-
performance_model: "O(n) where n=number of modules, O(n^2) for dependency graphs"
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢diagram:context.visualization
|
|
3
|
+
∂{subprocess,pathlib,typing}
|
|
4
|
+
⚠{context:has-architecture-modules,manus-render-diagram:available,output-dir:writable,syntax:valid-mermaid-d2}
|
|
5
|
+
⊨{∀diagram→valid-syntax,∀module-name:sanitized,¬modify-context,∀png-render→graceful-fail}
|
|
6
|
+
🔒{read:context-file,write:diagram-files}
|
|
7
|
+
⚡{O(n³):dependency-graph-generation|13-loops,depth=3}
|
|
22
8
|
|
|
23
9
|
Architecture Diagram Generator
|
|
24
10
|
|
|
25
|
-
Generates visual diagrams from context files.
|
|
11
|
+
Generates visual diagrams from context files in Mermaid and D2 formats.
|
|
26
12
|
"""
|
|
27
13
|
|
|
28
14
|
import subprocess
|
|
@@ -1,25 +1,10 @@
|
|
|
1
|
-
"""@
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
assumptions: [
|
|
9
|
-
"Python 3.7+ with dataclasses support",
|
|
10
|
-
"All dates are ISO 8601 format (YYYY-MM-DD)",
|
|
11
|
-
"Version strings follow semver (major.minor)",
|
|
12
|
-
"All text fields are UTF-8 strings"
|
|
13
|
-
]
|
|
14
|
-
invariants: [
|
|
15
|
-
"All dataclasses must be immutable (frozen=False but should not be mutated)",
|
|
16
|
-
"Optional fields must have None as default",
|
|
17
|
-
"List fields must use field(default_factory=list)",
|
|
18
|
-
"Dict fields must use field(default_factory=dict)",
|
|
19
|
-
"All models must be serializable to dict via asdict()"
|
|
20
|
-
]
|
|
21
|
-
security_model: "Pure data structures, no I/O or side effects"
|
|
22
|
-
performance_model: "O(1) for all operations, lightweight dataclasses"
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢models:context.data-structures
|
|
3
|
+
∂{dataclasses,typing,datetime}
|
|
4
|
+
⚠{python≥3.7,dates:iso8601,versions:semver,text:utf8}
|
|
5
|
+
⊨{∀dataclass:quasi-immutable,∀optional→None-default,∀list:default-factory,∀dict:default-factory,∀model→serializable-asdict}
|
|
6
|
+
🔒{pure-data,¬io,¬side-effects}
|
|
7
|
+
⚡{O(n):iteration-serialization|dataclass-operations}
|
|
23
8
|
|
|
24
9
|
Context System Data Models
|
|
25
10
|
|
|
@@ -1,29 +1,14 @@
|
|
|
1
|
-
"""@
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
assumptions: [
|
|
9
|
-
"PyYAML is installed and available",
|
|
10
|
-
"Files are UTF-8 encoded",
|
|
11
|
-
"YAML files follow .voodocs.context schema",
|
|
12
|
-
"File system is readable and writable"
|
|
13
|
-
]
|
|
14
|
-
invariants: [
|
|
15
|
-
"All YAML output must be valid and parseable",
|
|
16
|
-
"None values must be represented as empty strings, not 'null'",
|
|
17
|
-
"Indentation must be 2 spaces",
|
|
18
|
-
"Dict keys must preserve insertion order",
|
|
19
|
-
"Architecture decisions and modules must be converted to proper objects"
|
|
20
|
-
]
|
|
21
|
-
security_model: "Read/write context files only, no arbitrary file access"
|
|
22
|
-
performance_model: "O(n/c) for parsing where n=file size, c=10x speedup from LibYAML. Phase 3 optimizations: LibYAML C loader (10x), LRU caching (100x on cache hits), streamlined conversion (3x). Combined: 10-300x faster."
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢yaml-utils:context.serialization
|
|
3
|
+
∂{yaml,pathlib,models}
|
|
4
|
+
⚠{pyyaml:installed,encoding:utf8,schema:voodocs-context,fs:read-write}
|
|
5
|
+
⊨{∀yaml-output→valid-parseable,∀None→empty-string,indent:2-spaces,∀dict:preserve-order,∀arch→proper-objects}
|
|
6
|
+
🔒{read-write:context-files-only,¬arbitrary-file-access}
|
|
7
|
+
⚡{O(n/c):parse|n=file-size,c=10x-libyaml,cache:100x-hits,combined:10-300x}
|
|
23
8
|
|
|
24
9
|
YAML Utilities for Context Files
|
|
25
10
|
|
|
26
|
-
Handles reading, writing, and formatting of .voodocs.context YAML files.
|
|
11
|
+
Handles reading, writing, and formatting of .voodocs.context YAML files with LibYAML C backend optimization.
|
|
27
12
|
"""
|
|
28
13
|
|
|
29
14
|
import yaml
|
|
@@ -1,6 +1,16 @@
|
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢init:core.package
|
|
3
|
+
∂{}
|
|
4
|
+
⚠{python≥3.7}
|
|
5
|
+
⊨{∀import→exports-available,namespace:clean,¬side-effects-on-import}
|
|
6
|
+
🔒{pure-init,¬io,¬network,¬exec}
|
|
7
|
+
⚡{O(1):import-time}
|
|
8
|
+
|
|
9
|
+
Package initialization for core.
|
|
10
|
+
|
|
11
|
+
Module exports and namespace configuration.
|
|
1
12
|
"""
|
|
2
|
-
|
|
3
|
-
"""
|
|
13
|
+
|
|
4
14
|
|
|
5
15
|
from .plugin import (
|
|
6
16
|
DarkArtsPlugin,
|
|
@@ -1,6 +1,20 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢interface:core.api
|
|
3
|
+
∂{typing,darkarts.core.plugin,darkarts.core.registry,darkarts.core.loader}
|
|
4
|
+
⚠{python≥3.7,plugins:registered,registry:initialized}
|
|
5
|
+
⊨{∀solve→PluginOutput,∀plugin-call→routed-correctly,∀error→PluginError,auto-detect:best-effort,¬modify-registry-during-solve}
|
|
6
|
+
🔒{delegates-to-plugins,plugin-security-dependent,¬direct-file-io}
|
|
7
|
+
⚡{O(1):dispatch,O(p):plugin-execution|p=plugin-complexity}
|
|
8
|
+
|
|
2
9
|
Unified interface to the DarkArts platform.
|
|
3
|
-
|
|
10
|
+
|
|
11
|
+
Provides high-level API for problem solving with automatic plugin routing:
|
|
12
|
+
- Problem solving with plugin selection (manual or auto-detect)
|
|
13
|
+
- Plugin management (list, get, register, load)
|
|
14
|
+
- Explanation generation for solutions
|
|
15
|
+
- Learning mode for pattern recognition
|
|
16
|
+
- Built-in plugin discovery and loading
|
|
17
|
+
""""
|
|
4
18
|
|
|
5
19
|
from typing import Any, Dict, List, Optional
|
|
6
20
|
from .plugin import DarkArtsPlugin, PluginInput, PluginOutput, PluginMetadata, PluginError
|
|
@@ -1,6 +1,21 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢loader:core.plugin-discovery
|
|
3
|
+
∂{importlib,os,sys,pathlib,typing,darkarts.core.plugin,darkarts.core.registry}
|
|
4
|
+
⚠{python≥3.7,fs:readable,modules:importable,plugins:valid-subclass}
|
|
5
|
+
⊨{∀load→DarkArtsPlugin|PluginError,∀register→registry-updated,∀discovery→finds-all-valid,¬modify-source}
|
|
6
|
+
🔒{⚠️EXEC-CODE:import-plugins,read:plugin-dirs,¬network,¬arbitrary-file-write}
|
|
7
|
+
⚡{O(n)|n=plugins,import-overhead:per-plugin}
|
|
8
|
+
|
|
2
9
|
Plugin loader for discovering and loading plugins.
|
|
3
|
-
|
|
10
|
+
|
|
11
|
+
Dynamic plugin discovery and loading system with support for:
|
|
12
|
+
- Module-based loading (importlib)
|
|
13
|
+
- File-based loading (from .py files)
|
|
14
|
+
- Directory scanning (auto-discovery)
|
|
15
|
+
- Built-in plugin detection
|
|
16
|
+
- Automatic registry integration
|
|
17
|
+
- Plugin validation and error handling
|
|
18
|
+
""""
|
|
4
19
|
|
|
5
20
|
import importlib
|
|
6
21
|
import importlib.util
|
|
@@ -1,8 +1,21 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢plugin:core.extensibility
|
|
3
|
+
∂{abc,dataclasses,enum,typing}
|
|
4
|
+
⚠{python≥3.7,subclass:implements-abstract-methods}
|
|
5
|
+
⊨{∀plugin:DarkArtsPlugin-subclass,∀metadata:valid-schema,∀input→PluginInput,∀output→PluginOutput,∀abstract-method:must-implement,lifecycle:init→execute→cleanup}
|
|
6
|
+
🔒{interface-only,security:plugin-dependent,¬direct-io}
|
|
7
|
+
⚡{O(1):interface-dispatch,O(p):plugin-implementation|p=plugin-complexity}
|
|
8
|
+
|
|
2
9
|
Core plugin system for DarkArts.
|
|
3
10
|
|
|
4
|
-
|
|
5
|
-
|
|
11
|
+
Defines the base classes and interfaces for the DarkArts plugin system with:
|
|
12
|
+
- Abstract plugin interface (DarkArtsPlugin base class)
|
|
13
|
+
- Plugin capabilities (parse, analyze, execute, explain, learn, multi-step)
|
|
14
|
+
- Standardized input/output (PluginInput, PluginOutput dataclasses)
|
|
15
|
+
- Plugin metadata (name, version, description, dependencies, capabilities)
|
|
16
|
+
- Exception hierarchy (ParseError, ExecutionError, PluginError)
|
|
17
|
+
- Lifecycle management (initialization, execution, cleanup)
|
|
18
|
+
""""
|
|
6
19
|
|
|
7
20
|
from abc import ABC, abstractmethod
|
|
8
21
|
from dataclasses import dataclass, field
|
|
@@ -1,6 +1,21 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢registry:core.plugin-management
|
|
3
|
+
∂{typing,darkarts.core.plugin}
|
|
4
|
+
⚠{python≥3.7,plugins:valid-metadata}
|
|
5
|
+
⊨{∀register→unique-name|PluginError,∀get→plugin|None,∀unregister→removed,¬duplicate-names,∀deps→satisfied-before-register,thread-safe:dict-ops}
|
|
6
|
+
🔒{read-write:registry-only,¬file-io,¬network,in-memory-only}
|
|
7
|
+
⚡{O(1):register-get-unregister,O(n):list|n=plugin-count,dict-based}
|
|
8
|
+
|
|
2
9
|
Plugin registry for managing and discovering plugins.
|
|
3
|
-
|
|
10
|
+
|
|
11
|
+
Central registry for plugin lifecycle management with:
|
|
12
|
+
- Plugin registration with uniqueness enforcement
|
|
13
|
+
- Dependency validation (plugins must register dependencies first)
|
|
14
|
+
- Plugin lookup by name or capability
|
|
15
|
+
- Plugin enumeration and discovery
|
|
16
|
+
- Thread-safe operations (dict-based)
|
|
17
|
+
- Global singleton registry pattern
|
|
18
|
+
""""
|
|
4
19
|
|
|
5
20
|
from typing import Dict, List, Optional
|
|
6
21
|
from .plugin import DarkArtsPlugin, PluginMetadata, PluginError
|
|
@@ -1,8 +1,22 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢exceptions:errors.hierarchy
|
|
3
|
+
∂{}
|
|
4
|
+
⚠{python≥3.7}
|
|
5
|
+
⊨{∀exception:VooDocsError-subclass,∀error→informative-message,hierarchy:base→specific,catchable:by-type}
|
|
6
|
+
🔒{pure-exceptions,¬io,¬side-effects,¬exec}
|
|
7
|
+
⚡{O(1):exception-creation}
|
|
8
|
+
|
|
2
9
|
VooDocs Custom Exceptions
|
|
3
10
|
|
|
4
|
-
|
|
5
|
-
|
|
11
|
+
Structured exception hierarchy for error handling with:
|
|
12
|
+
- Base exception (VooDocsError for all VooDocs errors)
|
|
13
|
+
- Parser errors (ParserError, ParserNotBuiltError, AnnotationError)
|
|
14
|
+
- Validation errors (InvalidAnnotationError, ValidationError)
|
|
15
|
+
- Generator errors (GeneratorError)
|
|
16
|
+
- Configuration errors (ConfigurationError)
|
|
17
|
+
- File errors (FileNotFoundError)
|
|
18
|
+
- Informative messages (clear guidance for users)
|
|
19
|
+
""""
|
|
6
20
|
|
|
7
21
|
|
|
8
22
|
class VooDocsError(Exception):
|
|
@@ -1,6 +1,16 @@
|
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢init:plugins.voodocs.package
|
|
3
|
+
∂{}
|
|
4
|
+
⚠{python≥3.7}
|
|
5
|
+
⊨{∀import→exports-available,namespace:clean,¬side-effects-on-import}
|
|
6
|
+
🔒{pure-init,¬io,¬network,¬exec}
|
|
7
|
+
⚡{O(n²):plugin-initialization|10-loops,depth=2}
|
|
8
|
+
|
|
9
|
+
Package initialization for plugins.voodocs.
|
|
10
|
+
|
|
11
|
+
Module exports and namespace configuration.
|
|
1
12
|
"""
|
|
2
|
-
|
|
3
|
-
"""
|
|
13
|
+
|
|
4
14
|
|
|
5
15
|
import ast
|
|
6
16
|
import re
|
|
@@ -1,10 +1,21 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢ai-voodocs-plugin:plugins.documentation
|
|
3
|
+
∂{darkarts.core,darkarts.annotations,darkarts.plugins.voodocs.documentation_generator,darkarts.plugins.voodocs.test_generator,darkarts.plugins.voodocs.api_spec_generator}
|
|
4
|
+
⚠{python≥3.7,source-code:parseable,annotations:@voodocs-format}
|
|
5
|
+
⊨{∀parse→annotations-extracted,∀execute→docs-generated,∀analyze→insights,¬modify-source,idempotent:same-input→same-output}
|
|
6
|
+
🔒{read-only:source,write:docs-output,¬network,¬arbitrary-exec}
|
|
7
|
+
⚡{O(n)|n=source-lines,ast-parsing:linear}
|
|
8
|
+
|
|
2
9
|
AI-Native VooDocs Plugin for DarkArts
|
|
3
10
|
|
|
4
|
-
Enhanced
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
11
|
+
Enhanced documentation plugin supporting:
|
|
12
|
+
- @voodocs annotation parsing (AI-native documentation)
|
|
13
|
+
- Traditional AST-based documentation (fallback)
|
|
14
|
+
- Automatic documentation generation (Markdown, HTML, PDF)
|
|
15
|
+
- Test generation from annotations (preconditions/postconditions → tests)
|
|
16
|
+
- API specification generation (OpenAPI from annotations)
|
|
17
|
+
- Multi-format output (docs, tests, specs)
|
|
18
|
+
""""
|
|
8
19
|
|
|
9
20
|
from darkarts.core import (
|
|
10
21
|
DarkArtsPlugin,
|
|
@@ -1,8 +1,21 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢validator:plugins.quality-assurance
|
|
3
|
+
∂{typing,darkarts.annotations.types,re}
|
|
4
|
+
⚠{python≥3.7,annotations:parsed}
|
|
5
|
+
⊨{∀validate→issues-list,∀issue:categorized,∀severity:error|warning|info,¬modify-annotations,comprehensive:all-rules-checked}
|
|
6
|
+
🔒{read-only:annotations,¬file-io,¬network,¬exec}
|
|
7
|
+
⚡{O(n)|n=annotations,validation:linear}
|
|
8
|
+
|
|
2
9
|
VooDocs Annotation Validator
|
|
3
10
|
|
|
4
|
-
|
|
5
|
-
|
|
11
|
+
Quality assurance for @voodocs annotations with:
|
|
12
|
+
- Syntax validation (correct format and structure)
|
|
13
|
+
- Completeness checking (required fields present)
|
|
14
|
+
- Consistency verification (invariants don't contradict postconditions)
|
|
15
|
+
- Complexity notation validation (Big-O format)
|
|
16
|
+
- Security model checking (valid security declarations)
|
|
17
|
+
- Best practice recommendations (suggestions for improvement)
|
|
18
|
+
""""
|
|
6
19
|
|
|
7
20
|
from typing import List, Dict, Any, Optional
|
|
8
21
|
from darkarts.annotations.types import ParsedAnnotations, FunctionAnnotation, ClassAnnotation
|
|
@@ -1,8 +1,21 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢api-spec-generator:plugins.api-documentation
|
|
3
|
+
∂{typing,pathlib,json,yaml,darkarts.annotations.types}
|
|
4
|
+
⚠{python≥3.7,annotations:parsed,format:supported}
|
|
5
|
+
⊨{∀generate→api-spec,∀function→endpoint,∀annotation→schema,¬modify-annotations,valid-spec:parseable}
|
|
6
|
+
🔒{read-only:annotations,write:spec-files,¬network,¬exec}
|
|
7
|
+
⚡{O(n)|n=functions,spec-generation:linear}
|
|
8
|
+
|
|
2
9
|
DarkArts API Specification Generator
|
|
3
10
|
|
|
4
|
-
|
|
5
|
-
|
|
11
|
+
Automatic API specification generation from @voodocs annotations with:
|
|
12
|
+
- OpenAPI 3.0 generation (industry-standard REST API specs)
|
|
13
|
+
- Swagger support (compatible with Swagger UI)
|
|
14
|
+
- GraphQL schema generation (type-safe API definitions)
|
|
15
|
+
- Parameter extraction (from preconditions)
|
|
16
|
+
- Response schema generation (from postconditions)
|
|
17
|
+
- Error documentation (from error_cases)
|
|
18
|
+
""""
|
|
6
19
|
|
|
7
20
|
from typing import List, Optional, Dict, Any
|
|
8
21
|
from pathlib import Path
|
|
@@ -1,8 +1,21 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢doc-generator:plugins.translation
|
|
3
|
+
∂{typing,pathlib,re,darkarts.annotations.types}
|
|
4
|
+
⚠{python≥3.7,annotations:parsed,output-dir:writable}
|
|
5
|
+
⊨{∀generate→markdown-docs,∀translate→natural-language,∀symbol→readable,¬modify-annotations,idempotent:same-input→same-output}
|
|
6
|
+
🔒{read-only:annotations,write:docs-dir,¬network,¬exec}
|
|
7
|
+
⚡{O(n)|n=annotations,translation:linear}
|
|
8
|
+
|
|
2
9
|
VooDocs Documentation Generator
|
|
3
10
|
|
|
4
|
-
Translates @voodocs annotations (
|
|
5
|
-
|
|
11
|
+
Translates @voodocs annotations (DarkArts language) into human-readable documentation with:
|
|
12
|
+
- Mathematical symbol translation (∀, ∃, ∈, → natural language)
|
|
13
|
+
- Markdown generation (structured documentation)
|
|
14
|
+
- Multi-section output (module, classes, functions)
|
|
15
|
+
- Complexity notation explanation (Big-O → plain English)
|
|
16
|
+
- Security model documentation (clear security implications)
|
|
17
|
+
- Cross-reference generation (links between related items)
|
|
18
|
+
""""
|
|
6
19
|
|
|
7
20
|
from typing import List, Optional, Dict
|
|
8
21
|
from pathlib import Path
|
|
@@ -1,8 +1,21 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢html-exporter:plugins.export
|
|
3
|
+
∂{pathlib,typing}
|
|
4
|
+
⚠{python≥3.7,markdown:optional,input-file:exists}
|
|
5
|
+
⊨{∀export→html-file,∀markdown→html,¬modify-source,fallback:basic-conversion,styled:css-included}
|
|
6
|
+
🔒{read:markdown-files,write:html-files,¬network,¬exec}
|
|
7
|
+
⚡{O(n)|n=markdown-length,conversion:linear}
|
|
8
|
+
|
|
2
9
|
VooDocs HTML Exporter
|
|
3
10
|
|
|
4
|
-
|
|
5
|
-
|
|
11
|
+
Markdown to HTML conversion with styling:
|
|
12
|
+
- Markdown parsing (markdown library or fallback)
|
|
13
|
+
- Syntax highlighting (code blocks with CodeHilite)
|
|
14
|
+
- Table support (GitHub-flavored Markdown tables)
|
|
15
|
+
- Responsive CSS (mobile-friendly styling)
|
|
16
|
+
- Full HTML document wrapping (complete pages)
|
|
17
|
+
- Graceful degradation (basic conversion if markdown lib unavailable)
|
|
18
|
+
""""
|
|
6
19
|
|
|
7
20
|
from pathlib import Path
|
|
8
21
|
from typing import Optional
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
⚠{ai∈{cursor,claude,copilot,windsurf},format:markdown,@voodocs:taught}
|
|
5
5
|
⊨{∀gen→valid-format,∀gen→assistant-specific,∀gen→include-examples}
|
|
6
6
|
🔒{write:config-files}
|
|
7
|
-
⚡{O(
|
|
7
|
+
⚡{O(n):instruction-generation|template-based}
|
|
8
8
|
|
|
9
9
|
VooDocs AI Instruction Generator
|
|
10
10
|
|
|
@@ -1,8 +1,21 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢pdf-exporter:plugins.export
|
|
3
|
+
∂{pathlib,typing,subprocess,weasyprint,darkarts.plugins.voodocs.html_exporter}
|
|
4
|
+
⚠{python≥3.7,weasyprint|markdown-pdf:installed,input-file:exists}
|
|
5
|
+
⊨{∀export→pdf-file,∀markdown→pdf,¬modify-source,fallback-chain:weasyprint→markdown-pdf,print-ready:formatted}
|
|
6
|
+
🔒{read:markdown-files,write:pdf-files,¬network,¬exec}
|
|
7
|
+
⚡{O(n)|n=markdown-length,pdf-rendering:depends-on-lib}
|
|
8
|
+
|
|
2
9
|
VooDocs PDF Exporter
|
|
3
10
|
|
|
4
|
-
|
|
5
|
-
|
|
11
|
+
Markdown to PDF conversion with print-ready formatting:
|
|
12
|
+
- WeasyPrint support (HTML → PDF with CSS)
|
|
13
|
+
- Markdown-PDF fallback (alternative PDF generation)
|
|
14
|
+
- Print-optimized layout (page breaks, margins)
|
|
15
|
+
- Embedded fonts and styling (professional appearance)
|
|
16
|
+
- Multi-method fallback (tries multiple libraries)
|
|
17
|
+
- Error handling (clear messages if dependencies missing)
|
|
18
|
+
""""
|
|
6
19
|
|
|
7
20
|
from pathlib import Path
|
|
8
21
|
from typing import Optional
|
|
@@ -1,8 +1,21 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢test-generator:plugins.test-automation
|
|
3
|
+
∂{typing,pathlib,re,darkarts.annotations.types}
|
|
4
|
+
⚠{python≥3.7,annotations:parsed,framework:supported}
|
|
5
|
+
⊨{∀generate→test-code,∀precondition→test-case,∀postcondition→assertion,¬modify-annotations,executable:valid-syntax}
|
|
6
|
+
🔒{read-only:annotations,write:test-files,¬network,¬exec}
|
|
7
|
+
⚡{O(n)|n=functions,codegen:linear}
|
|
8
|
+
|
|
2
9
|
VooDocs Test Generator
|
|
3
10
|
|
|
4
|
-
|
|
5
|
-
|
|
11
|
+
Automatic test generation from @voodocs annotations with:
|
|
12
|
+
- Precondition tests (validate inputs match declared constraints)
|
|
13
|
+
- Postcondition tests (verify outputs satisfy guarantees)
|
|
14
|
+
- Invariant tests (check state consistency)
|
|
15
|
+
- Error case tests (ensure proper error handling)
|
|
16
|
+
- Property-based tests (Hypothesis/QuickCheck-style)
|
|
17
|
+
- Multi-framework support (pytest, unittest, jest, junit)
|
|
18
|
+
""""
|
|
6
19
|
|
|
7
20
|
from typing import List, Optional, Dict, Any, Tuple
|
|
8
21
|
from pathlib import Path
|
|
@@ -1,8 +1,21 @@
|
|
|
1
|
-
"""
|
|
1
|
+
"""@darkarts
|
|
2
|
+
⊢telemetry:analytics.privacy-first
|
|
3
|
+
∂{os,sys,json,uuid,platform,datetime,pathlib,typing,urllib}
|
|
4
|
+
⚠{python≥3.7,network:optional,config-dir:writable}
|
|
5
|
+
⊨{∀track→async-send,∀event:anonymous,∀user:opt-out-respected,¬pii,fail-silent:network-errors}
|
|
6
|
+
🔒{⚠️NETWORK:supabase-api,write:config-dir,¬sensitive-data,anonymous-only}
|
|
7
|
+
⚡{O(1):event-creation,network:async-non-blocking}
|
|
8
|
+
|
|
2
9
|
VooDocs Telemetry Client
|
|
3
10
|
|
|
4
|
-
Privacy-respecting anonymous
|
|
5
|
-
|
|
11
|
+
Privacy-respecting anonymous usage analytics with:
|
|
12
|
+
- Anonymous session IDs (UUID-based, no PII)
|
|
13
|
+
- Opt-out support (VOODOCS_TELEMETRY_DISABLED env var)
|
|
14
|
+
- Event tracking (command usage, errors, performance)
|
|
15
|
+
- Supabase backend (anonymous data storage)
|
|
16
|
+
- Fail-silent network (no impact on user experience if offline)
|
|
17
|
+
- First-run notice (transparent disclosure to users)
|
|
18
|
+
""""
|
|
6
19
|
|
|
7
20
|
import os
|
|
8
21
|
import sys
|