guidellm 0.3.0rc20250421__py3-none-any.whl → 0.3.0rc20250429__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.

Potentially problematic release.


This version of guidellm might be problematic. Click here for more details.

guidellm/utils/text.py CHANGED
@@ -115,11 +115,19 @@ def clean_text(text: str) -> str:
115
115
  return re.sub(r"\s+", " ", ftfy.fix_text(text)).strip()
116
116
 
117
117
 
118
- def split_text(text: str, split_punctuation: bool = False) -> list[str]:
118
+ def split_text(
119
+ text: str, split_punctuation: bool = False, split_whitespace: bool = False
120
+ ) -> list[str]:
119
121
  text = clean_text(text)
120
122
 
123
+ if split_punctuation and split_whitespace:
124
+ return re.findall(r"\w+|\s+|[^\w\s]", text)
125
+
121
126
  if split_punctuation:
122
- return re.findall(r"[\w]+|[.,!?;]", text)
127
+ return re.findall(r"\w+|[^\w\s]", text)
128
+
129
+ if split_whitespace:
130
+ return re.findall(r"\S+|\s+", text)
123
131
 
124
132
  return text.split()
125
133
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: guidellm
3
- Version: 0.3.0rc20250421
3
+ Version: 0.3.0rc20250429
4
4
  Summary: Guidance platform for deploying and managing large language models.
5
5
  Author: Neuralmagic, Inc.
6
6
  License: Apache License
@@ -228,6 +228,7 @@ Requires-Dist: pre-commit~=3.5.0; extra == "dev"
228
228
  Requires-Dist: scipy~=1.10; extra == "dev"
229
229
  Requires-Dist: sphinx~=7.1.2; extra == "dev"
230
230
  Requires-Dist: tox~=4.16.0; extra == "dev"
231
+ Requires-Dist: fastapi; extra == "dev"
231
232
  Requires-Dist: lorem~=0.1.1; extra == "dev"
232
233
  Requires-Dist: pytest~=8.2.2; extra == "dev"
233
234
  Requires-Dist: pytest-asyncio~=0.23.8; extra == "dev"
@@ -236,6 +237,7 @@ Requires-Dist: pytest-mock~=3.14.0; extra == "dev"
236
237
  Requires-Dist: pytest-rerunfailures~=14.0; extra == "dev"
237
238
  Requires-Dist: requests-mock~=1.12.1; extra == "dev"
238
239
  Requires-Dist: respx~=0.22.0; extra == "dev"
240
+ Requires-Dist: uvicorn; extra == "dev"
239
241
  Requires-Dist: mypy~=1.10.1; extra == "dev"
240
242
  Requires-Dist: ruff~=0.5.2; extra == "dev"
241
243
  Requires-Dist: mdformat~=0.7.17; extra == "dev"
@@ -39,10 +39,10 @@ guidellm/utils/__init__.py,sha256=Tg4HT5RiXSnQ48E-NuJJf0-fwyvqo5sgk7yFSc8WZ78,52
39
39
  guidellm/utils/colors.py,sha256=D0IGz8A346-Pt5qgnP3S5uV-VgngJoXbfToVCOna41k,175
40
40
  guidellm/utils/hf_transformers.py,sha256=3iF40l02VEWOcS8kasO8TSws0Lp3cE-NyiqoB9GnHuA,1021
41
41
  guidellm/utils/random.py,sha256=Ub7cI8J0ZfTkjO_x98KHvVKYs_jUlgmjRp67p-lhY5c,1314
42
- guidellm/utils/text.py,sha256=8ei6_Sj_rPRV6lW7yivV9UwgXPzRtNMxNkJ8m0e8RX0,6347
43
- guidellm-0.3.0rc20250421.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
44
- guidellm-0.3.0rc20250421.dist-info/METADATA,sha256=pftSm9Sb9p4FvzEHEFQbjGV-at-h48stvoVdGc6Jrhs,30335
45
- guidellm-0.3.0rc20250421.dist-info/WHEEL,sha256=pxyMxgL8-pra_rKaQ4drOZAegBVuX-G_4nRHjjgWbmo,91
46
- guidellm-0.3.0rc20250421.dist-info/entry_points.txt,sha256=DzLFEg47fF7qY1b-9laPz9jg0KSKJ1_D9TbF93kLz_E,51
47
- guidellm-0.3.0rc20250421.dist-info/top_level.txt,sha256=EXRGjnvFtL6MeZTe0tnHRMYcEWUW3vEqoG2zO7vFOtk,9
48
- guidellm-0.3.0rc20250421.dist-info/RECORD,,
42
+ guidellm/utils/text.py,sha256=BTtBol3tCAmUah_x6-G6x_XgnThTED7iozGB3ZRHQTU,6553
43
+ guidellm-0.3.0rc20250429.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
44
+ guidellm-0.3.0rc20250429.dist-info/METADATA,sha256=I2SWk9k8dcVk0qJs4K5og9OG2r3U9a-Kz2LJOMOnLug,30413
45
+ guidellm-0.3.0rc20250429.dist-info/WHEEL,sha256=ck4Vq1_RXyvS4Jt6SI0Vz6fyVs4GWg7AINwpsaGEgPE,91
46
+ guidellm-0.3.0rc20250429.dist-info/entry_points.txt,sha256=DzLFEg47fF7qY1b-9laPz9jg0KSKJ1_D9TbF93kLz_E,51
47
+ guidellm-0.3.0rc20250429.dist-info/top_level.txt,sha256=EXRGjnvFtL6MeZTe0tnHRMYcEWUW3vEqoG2zO7vFOtk,9
48
+ guidellm-0.3.0rc20250429.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (79.0.0)
2
+ Generator: setuptools (80.0.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5