Daybook: a self-hosted, multi-user Django + DRF app where agents, scripts, or people publish artifacts and each logged-in user browses their own time-ordered, label-filterable feed. This squashes prior local development history (kept privately on a separate branch) into a single clean starting point for the public repository. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
27 lines
1.2 KiB
Python
27 lines
1.2 KiB
Python
from django.db import migrations, models
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
initial = True
|
|
|
|
dependencies = []
|
|
|
|
operations = [
|
|
migrations.CreateModel(
|
|
name="Artifact",
|
|
fields=[
|
|
("id", models.CharField(max_length=8, primary_key=True, serialize=False)),
|
|
("persona", models.CharField(db_index=True, max_length=80)),
|
|
("title", models.CharField(max_length=200)),
|
|
("kind", models.CharField(choices=[("html_fragment", "HTML fragment"), ("html_full", "Full HTML"), ("markdown", "Markdown"), ("deck", "Deck"), ("image", "Image"), ("pdf", "PDF"), ("binary", "Binary")], max_length=20)),
|
|
("theme", models.CharField(blank=True, max_length=40)),
|
|
("day", models.DateField(db_index=True)),
|
|
("created_at", models.DateTimeField(auto_now_add=True)),
|
|
("path", models.CharField(max_length=500)),
|
|
("original_kind", models.CharField(max_length=20)),
|
|
("tags", models.JSONField(blank=True, default=list)),
|
|
("source_prompt", models.TextField(blank=True)),
|
|
],
|
|
options={"ordering": ["-created_at"]},
|
|
),
|
|
]
|