Increase max_length for LLM config fields

This commit is contained in:
shamoon
2025-11-30 07:50:55 -08:00
parent 86192fb74c
commit 33c4758ef4
2 changed files with 12 additions and 12 deletions

View File

@@ -24,7 +24,7 @@ class Migration(migrations.Migration):
name="llm_api_key",
field=models.CharField(
blank=True,
max_length=128,
max_length=1024,
null=True,
verbose_name="Sets the LLM API key",
),
@@ -35,7 +35,7 @@ class Migration(migrations.Migration):
field=models.CharField(
blank=True,
choices=[("openai", "OpenAI"), ("ollama", "Ollama")],
max_length=32,
max_length=128,
null=True,
verbose_name="Sets the LLM backend",
),
@@ -46,7 +46,7 @@ class Migration(migrations.Migration):
field=models.CharField(
blank=True,
choices=[("openai", "OpenAI"), ("huggingface", "Huggingface")],
max_length=32,
max_length=128,
null=True,
verbose_name="Sets the LLM embedding backend",
),
@@ -56,7 +56,7 @@ class Migration(migrations.Migration):
name="llm_embedding_model",
field=models.CharField(
blank=True,
max_length=32,
max_length=128,
null=True,
verbose_name="Sets the LLM embedding model",
),
@@ -66,7 +66,7 @@ class Migration(migrations.Migration):
name="llm_endpoint",
field=models.CharField(
blank=True,
max_length=128,
max_length=256,
null=True,
verbose_name="Sets the LLM endpoint, optional",
),
@@ -76,7 +76,7 @@ class Migration(migrations.Migration):
name="llm_model",
field=models.CharField(
blank=True,
max_length=32,
max_length=128,
null=True,
verbose_name="Sets the LLM model",
),

View File

@@ -293,7 +293,7 @@ class ApplicationConfiguration(AbstractSingletonModel):
verbose_name=_("Sets the LLM embedding backend"),
blank=True,
null=True,
max_length=32,
max_length=128,
choices=LLMEmbeddingBackend.choices,
)
@@ -301,14 +301,14 @@ class ApplicationConfiguration(AbstractSingletonModel):
verbose_name=_("Sets the LLM embedding model"),
blank=True,
null=True,
max_length=32,
max_length=128,
)
llm_backend = models.CharField(
verbose_name=_("Sets the LLM backend"),
blank=True,
null=True,
max_length=32,
max_length=128,
choices=LLMBackend.choices,
)
@@ -316,21 +316,21 @@ class ApplicationConfiguration(AbstractSingletonModel):
verbose_name=_("Sets the LLM model"),
blank=True,
null=True,
max_length=32,
max_length=128,
)
llm_api_key = models.CharField(
verbose_name=_("Sets the LLM API key"),
blank=True,
null=True,
max_length=128,
max_length=1024,
)
llm_endpoint = models.CharField(
verbose_name=_("Sets the LLM endpoint, optional"),
blank=True,
null=True,
max_length=128,
max_length=256,
)
class Meta: