cocoindex 0.1.48__cp312-cp312-win_amd64.whl → 0.1.49__cp312-cp312-win_amd64.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.
Binary file
cocoindex/functions.py CHANGED
@@ -1,6 +1,7 @@
1
1
  """All builtin functions."""
2
2
 
3
3
  from typing import Annotated, Any, TYPE_CHECKING
4
+ import dataclasses
4
5
 
5
6
  from .typing import Float32, Vector, TypeAttr
6
7
  from . import op, llm
@@ -14,9 +15,20 @@ class ParseJson(op.FunctionSpec):
14
15
  """Parse a text into a JSON object."""
15
16
 
16
17
 
18
+ @dataclasses.dataclass
19
+ class CustomLanguageSpec:
20
+ """Custom language specification."""
21
+
22
+ language_name: str
23
+ separators_regex: list[str]
24
+ aliases: list[str] = dataclasses.field(default_factory=list)
25
+
26
+
17
27
  class SplitRecursively(op.FunctionSpec):
18
28
  """Split a document (in string) recursively."""
19
29
 
30
+ custom_languages: list[CustomLanguageSpec] = dataclasses.field(default_factory=list)
31
+
20
32
 
21
33
  class ExtractByLlm(op.FunctionSpec):
22
34
  """Extract information from a text using a LLM."""
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: cocoindex
3
- Version: 0.1.48
3
+ Version: 0.1.49
4
4
  Requires-Dist: sentence-transformers>=3.3.1
5
5
  Requires-Dist: click>=8.1.8
6
6
  Requires-Dist: rich>=14.0.0
@@ -1,14 +1,14 @@
1
- cocoindex-0.1.48.dist-info/METADATA,sha256=9q8sT9BPcllLbxgNb3aWerH_GPcv--jXaAuKn1rQtKY,10040
2
- cocoindex-0.1.48.dist-info/WHEEL,sha256=YpU2aDuTyBIvwRZn8idqScP-vkQ8DUGkCILtYmMfnFY,96
3
- cocoindex-0.1.48.dist-info/entry_points.txt,sha256=_NretjYVzBdNTn7dK-zgwr7YfG2afz1u1uSE-5bZXF8,46
4
- cocoindex-0.1.48.dist-info/licenses/LICENSE,sha256=HrhfyXIkWY2tGFK11kg7vPCqhgh5DcxleloqdhrpyMY,11558
1
+ cocoindex-0.1.49.dist-info/METADATA,sha256=s1ZnlhLjOHMMNUyZGTdr7vQG55ffcZpBqihwwA-bvS0,10040
2
+ cocoindex-0.1.49.dist-info/WHEEL,sha256=YpU2aDuTyBIvwRZn8idqScP-vkQ8DUGkCILtYmMfnFY,96
3
+ cocoindex-0.1.49.dist-info/entry_points.txt,sha256=_NretjYVzBdNTn7dK-zgwr7YfG2afz1u1uSE-5bZXF8,46
4
+ cocoindex-0.1.49.dist-info/licenses/LICENSE,sha256=HrhfyXIkWY2tGFK11kg7vPCqhgh5DcxleloqdhrpyMY,11558
5
5
  cocoindex/__init__.py,sha256=M_Iy0BCuceR537ZLz4dunGq8KYT060LF0N48sDnyIwM,835
6
- cocoindex/_engine.cp312-win_amd64.pyd,sha256=t2yLT_W6wE0_91ojO5u-R_O4fv_VsORZGp5Hmo-nnMo,61456384
6
+ cocoindex/_engine.cp312-win_amd64.pyd,sha256=EO56SJz0YcXaT4ok9dHtK8baUvbUq2HVTY1Nt12c4v8,61498880
7
7
  cocoindex/auth_registry.py,sha256=LojDKoX0ccO-G3bboFMlAti50_t5GK9BS0ouPJZfyUs,745
8
8
  cocoindex/cli.py,sha256=zhSK6eDLn2UlKWrVTg2xZ89S-xB1XEH4pYWcz1xGS-Y,18411
9
9
  cocoindex/convert.py,sha256=Jc9hKaudlN4rOgXyXNs5O965xBqm7SURvjzpuVrutrY,7528
10
10
  cocoindex/flow.py,sha256=ElTNrp9cxUZiKSvLMRwjU9rNQUn2d9zxryJzCxCFx4I,30985
11
- cocoindex/functions.py,sha256=tVP-sCe5m0PdUjEPPLQE9dxh0dBmj6QsYb-Wt84a8YI,2036
11
+ cocoindex/functions.py,sha256=iJWfznAFu3COgA5027JNL-d-yNL4G3opdzbzBGOj7CM,2370
12
12
  cocoindex/index.py,sha256=GrqTm1rLwICQ8hadtNvJAxVg7GWMvtMmFcbiNtNzmP0,569
13
13
  cocoindex/lib.py,sha256=NsAhzFeAbBNWBZqDe9oUsjHa2IV0LSvq8CGqSbS0C1Q,3061
14
14
  cocoindex/llm.py,sha256=sI46pXpTmOLOBOBpqCB2pnwDHz4PdVyEPBKZuIxObpU,372
@@ -24,4 +24,4 @@ cocoindex/tests/__init__.py,sha256=frcCV1k9oG9oKj3dpUqdJg1PxRT2RSN_XKdLCPjaYaY,2
24
24
  cocoindex/tests/test_convert.py,sha256=-8DI7B2nKneeBVLzovAhngbMjHi9vYJ1TCixl-XosYQ,17634
25
25
  cocoindex/typing.py,sha256=_Hj79DiYZ5LOkkPqu-uScup9Qy_035fb2QOVNL-44KY,9780
26
26
  cocoindex/utils.py,sha256=RLyawj_M4ZDL-gwJ16e5p2AcFYIL50DlMkfZyKaNB2o,520
27
- cocoindex-0.1.48.dist-info/RECORD,,
27
+ cocoindex-0.1.49.dist-info/RECORD,,