OpenRAG 0.4.0.dev4__py3-none-any.whl → 0.4.0.dev6__py3-none-any.whl

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.
api/settings.py CHANGED
@@ -607,6 +607,12 @@ async def update_settings(
607
607
  logger.error(f"Failed to update docling settings in flow: {str(e)}")
608
608
 
609
609
  if body.chunk_size is not None:
610
+ effective_overlap = body.chunk_overlap if body.chunk_overlap is not None else current_config.knowledge.chunk_overlap
611
+ if effective_overlap >= body.chunk_size:
612
+ raise HTTPException(
613
+ status_code=422,
614
+ detail="chunk_overlap must be less than chunk_size"
615
+ )
610
616
  current_config.knowledge.chunk_size = body.chunk_size
611
617
  config_updated = True
612
618
  await TelemetryClient.send_event(
@@ -627,6 +633,12 @@ async def update_settings(
627
633
  # The config will still be saved
628
634
 
629
635
  if body.chunk_overlap is not None:
636
+ effective_chunk_size = body.chunk_size if body.chunk_size is not None else current_config.knowledge.chunk_size
637
+ if body.chunk_overlap >= effective_chunk_size:
638
+ raise HTTPException(
639
+ status_code=422,
640
+ detail="chunk_overlap must be less than chunk_size"
641
+ )
630
642
  current_config.knowledge.chunk_overlap = body.chunk_overlap
631
643
  config_updated = True
632
644
  await TelemetryClient.send_event(
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: openrag
3
- Version: 0.4.0.dev4
3
+ Version: 0.4.0.dev6
4
4
  Summary: OpenRAG is a comprehensive Retrieval-Augmented Generation platform that enables intelligent document search and AI-powered conversations.
5
5
  Classifier: Development Status :: 4 - Beta
6
6
  Classifier: Environment :: Console
@@ -21,7 +21,7 @@ api/provider_health.py,sha256=u4gNGhEAqsQY1ml6xWzWWAOfLHDrSVYPkw1NAmBCMsI,9690
21
21
  api/provider_validation.py,sha256=54w-2qQQS9MHrgsLghpsDkCs5EQxFoUZrp_31GPK7JM,31421
22
22
  api/router.py,sha256=nOusNdc-eOMRZo6a5eqNb91oOoleYNomHTGcKuPsMmU,6229
23
23
  api/search.py,sha256=PFL2-ReVCCzJmT31IDZlFhQm3eXSPgb9LS4mnnsc_58,2010
24
- api/settings.py,sha256=khop89asYhh6_gjJNjZ9bvfE__mw1DZedD5uEehElAg,80534
24
+ api/settings.py,sha256=55oKyc6GdTMsC2BAWWTNfezJ15r2tYrRnxLekpau5iU,81226
25
25
  api/tasks.py,sha256=j3tAfpE_X4UxhiGPrgea5jkxILF6HZK9Hoy3QTFGG0g,1524
26
26
  api/upload.py,sha256=gl47Ue_d6q-YgI019lspnmPQ22PMmFch7Z9E0tsgb6U,6649
27
27
  api/v1/__init__.py,sha256=A7dLY63RcJv6ii-Xh7WgREcwXixjzOXz2w5C0LGWTCc,190
@@ -66,7 +66,7 @@ models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
66
66
  models/processors.py,sha256=zOeZbFKUi6uPA3Qb3SF4-kPc2IuElsgZUeiH3IU9hZk,32496
67
67
  models/tasks.py,sha256=9iINXQZxA9-hcYzG8xC_baBfLa2w6gcRPJdQHsx_Kms,1643
68
68
  models/url.py,sha256=92rsrLLyIqUErYipYz5QwUNTdHwJ2jBRV7PIVpncTyo,5764
69
- openrag-0.4.0.dev4.dist-info/licenses/LICENSE,sha256=jWcnPXkUxEinX60Yn-_zjsY9i84vz2QSb0fi53djOkg,11334
69
+ openrag-0.4.0.dev6.dist-info/licenses/LICENSE,sha256=jWcnPXkUxEinX60Yn-_zjsY9i84vz2QSb0fi53djOkg,11334
70
70
  services/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
71
71
  services/api_key_service.py,sha256=B3yNdBBtvLjx3W3r1_CVrLktihZ4vdR_Xx8T2CbaALM,11541
72
72
  services/auth_service.py,sha256=7DTB92R_H8x4BL0x6ngvZHt5-WF4PXd2PWsWaRShqMw,22346
@@ -151,8 +151,8 @@ utils/telemetry/__init__.py,sha256=xoStY8hoYWnVe0B_jNthSdzRb7AxCT0rhM8ba9Q0Obg,2
151
151
  utils/telemetry/category.py,sha256=wei3V5WyUaiadYjEE5s0ys9PY0TjnebIvTykQU0P_2k,1114
152
152
  utils/telemetry/client.py,sha256=RhjW1a27w7W6gHt9X7AxdRPdZGmCEQDPskkxj5nsuiQ,12500
153
153
  utils/telemetry/message_id.py,sha256=IAu0wBVNOGPcSlQ0bAzvqIYr1Ac_n8wSTSxXzq_tiV0,9634
154
- openrag-0.4.0.dev4.dist-info/METADATA,sha256=RmOjXEtWEt6-uTF1MiXF_2-biO6BZXcEM9nmf3lis1s,7456
155
- openrag-0.4.0.dev4.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91
156
- openrag-0.4.0.dev4.dist-info/entry_points.txt,sha256=ArKNHB63I3K8vynNkogvZOLmmQFpIsHDL7MvreCmju4,45
157
- openrag-0.4.0.dev4.dist-info/top_level.txt,sha256=uOXDYvPnDHWjAKsqgz_7wX5PGLxkDN6k3g8dNZ7Nuv0,101
158
- openrag-0.4.0.dev4.dist-info/RECORD,,
154
+ openrag-0.4.0.dev6.dist-info/METADATA,sha256=Gu-lC5bCFyXGg5Azyh09OIOQmifcfV82otOugeIs4iY,7456
155
+ openrag-0.4.0.dev6.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91
156
+ openrag-0.4.0.dev6.dist-info/entry_points.txt,sha256=ArKNHB63I3K8vynNkogvZOLmmQFpIsHDL7MvreCmju4,45
157
+ openrag-0.4.0.dev6.dist-info/top_level.txt,sha256=uOXDYvPnDHWjAKsqgz_7wX5PGLxkDN6k3g8dNZ7Nuv0,101
158
+ openrag-0.4.0.dev6.dist-info/RECORD,,