diff --git a/src/paperless/migrations/0005_applicationconfiguration_ai_enabled_and_more.py b/src/paperless/migrations/0005_applicationconfiguration_ai_enabled_and_more.py index df0de8351..f8a71ea6b 100644 --- a/src/paperless/migrations/0005_applicationconfiguration_ai_enabled_and_more.py +++ b/src/paperless/migrations/0005_applicationconfiguration_ai_enabled_and_more.py @@ -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", ), diff --git a/src/paperless/models.py b/src/paperless/models.py index 81ad8b176..0f727972a 100644 --- a/src/paperless/models.py +++ b/src/paperless/models.py @@ -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: