Files
LLMUtils/prompts/code_generator.md
2025-09-16 16:05:01 +02:00

32 lines
667 B
Markdown

Generate a Python class with the following specifications:
Class Name: {{ class_name }}
{% if parent_class %}
Inherits from: {{ parent_class }}
{% endif %}
## Attributes:
{% for attr in attributes %}
- {{ attr.name }}: {{ attr.type }}{% if attr.default %} = {{ attr.default }}{% endif %}
{% endfor %}
## Methods:
{% for method in methods %}
### {{ method.name }}({{ method.params | join(', ') }})
{{ method.description }}
Returns: {{ method.returns }}
{% endfor %}
## Example Usage:
```python
{% for example in examples %}
{{ example }}
{% endfor %}
```
{% if additional_notes %}
## Notes:
{% for note in additional_notes %}
- {{ note }}
{% endfor %}
{% endif %}