gllm-core-binary 0.4.9__cp313-cp313-win_amd64.whl → 0.4.10__cp313-cp313-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.
@@ -1,28 +1,6 @@
1
- from _typeshed import Incomplete
1
+ from gllm_core.utils import get_value_repr as get_value_repr
2
2
  from pydantic import BaseModel
3
- from typing import Any, Generic, Iterable, TypeVar
4
-
5
- MAX_PREVIEW_LENGTH: int
6
- MAX_ITEMS_PREVIEW: int
7
- T = TypeVar('T')
8
-
9
- class _TruncatedIterable(Generic[T]):
10
- """Represents a truncated iterable with first and last elements visible.
11
-
12
- Attributes:
13
- items (Iterable[T]): The iterable to be truncated.
14
- max_items_preview (int): Maximum number of items to show before truncation.
15
- """
16
- items: Incomplete
17
- max_items_preview: Incomplete
18
- def __init__(self, items: Iterable[T], max_items_preview: int = ...) -> None:
19
- """Initialize a TruncatedIterable.
20
-
21
- Args:
22
- items (Iterable[T]): The iterable to be truncated.
23
- max_items_preview (int, optional): Maximum number of items to show before truncation.
24
- Defaults to MAX_ITEMS_PREVIEW.
25
- """
3
+ from typing import Any
26
4
 
27
5
  class Chunk(BaseModel, arbitrary_types_allowed=True):
28
6
  """Represents a chunk of content retrieved from a vector store.
@@ -7,7 +7,8 @@ from gllm_core.utils.google_sheets import load_gsheets as load_gsheets
7
7
  from gllm_core.utils.logger_manager import LoggerManager as LoggerManager
8
8
  from gllm_core.utils.main_method_resolver import MainMethodResolver as MainMethodResolver
9
9
  from gllm_core.utils.merger_method import MergerMethod as MergerMethod
10
+ from gllm_core.utils.repr import get_value_repr as get_value_repr
10
11
  from gllm_core.utils.retry import RetryConfig as RetryConfig, retry as retry
11
12
  from gllm_core.utils.validation import validate_enum as validate_enum, validate_string_enum as validate_string_enum
12
13
 
13
- __all__ = ['BinaryHandlingStrategy', 'ChunkMetadataMerger', 'LoggerManager', 'MainMethodResolver', 'MergerMethod', 'RunAnalyzer', 'RetryConfig', 'asyncify', 'get_default_portal', 'binary_handler_factory', 'format_chunk_message', 'get_placeholder_keys', 'load_gsheets', 'syncify', 'retry', 'validate_enum', 'validate_string_enum']
14
+ __all__ = ['BinaryHandlingStrategy', 'ChunkMetadataMerger', 'LoggerManager', 'MainMethodResolver', 'MergerMethod', 'RunAnalyzer', 'RetryConfig', 'asyncify', 'get_default_portal', 'binary_handler_factory', 'format_chunk_message', 'get_placeholder_keys', 'get_value_repr', 'load_gsheets', 'syncify', 'retry', 'validate_enum', 'validate_string_enum']
@@ -1,15 +1,15 @@
1
1
  from _typeshed import Incomplete
2
- from gllm_core.schema import Chunk as Chunk
3
- from gllm_core.schema.chunk import MAX_PREVIEW_LENGTH as MAX_PREVIEW_LENGTH
2
+ from gllm_core.schema.chunk import Chunk as Chunk
3
+ from gllm_core.utils.repr import MAX_PREVIEW_LENGTH as MAX_PREVIEW_LENGTH
4
4
 
5
5
  TEMPLATE_VALIDATOR_REGEX: Incomplete
6
6
 
7
- def format_chunk_message(chunk: Chunk, rank: int = None, include_score: bool = True, include_metadata: bool = True) -> str:
7
+ def format_chunk_message(chunk: Chunk, rank: int | None = None, include_score: bool = True, include_metadata: bool = True) -> str:
8
8
  """Formats a log to display a single chunk.
9
9
 
10
10
  Args:
11
11
  chunk (Chunk): The chunk to be formatted.
12
- rank (int, optional): The optional rank of the formatted chunk. Defaults to None.
12
+ rank (int | None, optional): The optional rank of the formatted chunk. Defaults to None.
13
13
  include_score (bool, optional): Whether to include the score in the formatted message. Defaults to True.
14
14
  include_metadata (bool, optional): Whether to include the metadata in the formatted message. Defaults to True.
15
15
 
@@ -7,12 +7,12 @@ def check_optional_packages(packages: str | list[str], error_message: str | None
7
7
  packages (str | list[str]): Package name or list of package names to check.
8
8
  error_message (str | None, optional): Custom error message. If None, a default message is used.
9
9
  Defaults to None.
10
- install_instructions (str | None, optional): Installation instructions. If None, generates poetry install
10
+ install_instructions (str | None, optional): Installation instructions. If None, generates uv sync
11
11
  command. Defaults to None.
12
- extras (str | list[str] | None, optional): Poetry extras that contain the required packages. If provided,
13
- generates specific installation instructions. If install_instructions is None, it will create
14
- default instructions based on the extras. If install_instructions is not None, it will use the
15
- provided instructions directly and ignore this argument. Defaults to None.
12
+ extras (str | list[str] | None, optional): Extras that contain the required packages. If provided,
13
+ generates specific installation instructions using uv sync. If install_instructions is None,
14
+ it will create default instructions based on the extras. If install_instructions is not None,
15
+ it will use the provided instructions directly and ignore this argument. Defaults to None.
16
16
 
17
17
  Raises:
18
18
  ImportError: If any of the required packages are not installed.
@@ -0,0 +1,34 @@
1
+ from _typeshed import Incomplete
2
+ from typing import Any, Generic, Iterable, TypeVar
3
+
4
+ MAX_PREVIEW_LENGTH: int
5
+ MAX_ITEMS_PREVIEW: int
6
+ T = TypeVar('T')
7
+
8
+ class _TruncatedIterable(Generic[T]):
9
+ """Represents a truncated iterable with first and last elements visible.
10
+
11
+ Attributes:
12
+ items (Iterable[T]): The iterable to be truncated.
13
+ max_items_preview (int): Maximum number of items to show before truncation.
14
+ """
15
+ items: Incomplete
16
+ max_items_preview: Incomplete
17
+ def __init__(self, items: Iterable[T], max_items_preview: int = ...) -> None:
18
+ """Initialize a TruncatedIterable.
19
+
20
+ Args:
21
+ items (Iterable[T]): The iterable to be truncated.
22
+ max_items_preview (int, optional): Maximum number of items to show before truncation.
23
+ Defaults to MAX_ITEMS_PREVIEW.
24
+ """
25
+
26
+ def get_value_repr(value: Any) -> Any:
27
+ """Get the string representation of a value.
28
+
29
+ Args:
30
+ value (Any): The value to get the string representation of.
31
+
32
+ Returns:
33
+ Any: The string representation of the value.
34
+ """
Binary file
gllm_core.pyi CHANGED
@@ -32,6 +32,7 @@ import gllm_core.schema.main
32
32
  import gllm_core.utils.get_placeholder_keys
33
33
  import uuid
34
34
  import pydantic
35
+ import gllm_core.utils.get_value_repr
35
36
  import __future__
36
37
  import inspect
37
38
  import logging
@@ -49,7 +50,6 @@ import anyio
49
50
  import anyio.abc
50
51
  import anyio.from_thread
51
52
  import re
52
- import gllm_core.schema.Chunk
53
53
  import gspread
54
54
  import google
55
55
  import google.oauth2
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: gllm-core-binary
3
- Version: 0.4.9
3
+ Version: 0.4.10
4
4
  Summary: A library containing core components for Gen AI applications.
5
5
  Author-email: Dimitrij Ray <dimitrij.ray@gdplabs.id>, Henry Wicaksono <henry.wicaksono@gdplabs.id>, Resti Febriana <resti.febriana@gdplabs.id>
6
6
  Requires-Python: <3.14,>=3.11
@@ -1,5 +1,5 @@
1
- gllm_core.cp313-win_amd64.pyd,sha256=hk_zzdH2xWGYPu5q3v_DoOCK_E2e54MrkpVjMijK74o,1215488
2
- gllm_core.pyi,sha256=ac4MFViPSzPCZnQxhTCUzyfFa70IsLDKnOQDZV7QV_c,1468
1
+ gllm_core.cp313-win_amd64.pyd,sha256=skECswHfCW7LLByGerFP9Ci-TwPNRYzA69wz6L6o4sU,1222144
2
+ gllm_core.pyi,sha256=kBd25H_G7jvs1UzU5b1G-3b46959nW49bhvo66PkEOM,1476
3
3
  gllm_core/__init__.pyi,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
4
4
  gllm_core/constants.pyi,sha256=HfDsdHcPhUsSniEp_fScuVnSuhpJOM17rQIU2dV2DY8,843
5
5
  gllm_core/adapters/__init__.pyi,sha256=N8JBGr2mPUMAGaMd__7XxGr2NAzfaFMuNH15QkSfbrA,187
@@ -18,27 +18,28 @@ gllm_core/event/hook/__init__.pyi,sha256=gSDHYl0yi00zHHMRvU_Eg8qLqsGHESTvoNE3MXi
18
18
  gllm_core/event/hook/event_hook.pyi,sha256=IV5oq-ZZqrLG_hvdibphCpWDYu9e5lYuarQxt8dn76Y,565
19
19
  gllm_core/event/hook/json_stringify_event_hook.pyi,sha256=I-QxbaLc4rEyqhW_f4INN5UxBg_ZofHHN1HQKfPJ7rs,585
20
20
  gllm_core/schema/__init__.pyi,sha256=X7Gv3xgtl4Ylzsg9iuGgjJPkQey7OdvvIC_X1e5_LAI,310
21
- gllm_core/schema/chunk.pyi,sha256=ZVYQitMtvMStiFssnTCgtSIcj30VSsK2dKscSysl3R4,2378
21
+ gllm_core/schema/chunk.pyi,sha256=rkglyHC8dlAE8FpamA9NciY13nTJKZLzQg3gxMUalFA,1591
22
22
  gllm_core/schema/component.pyi,sha256=KJcGMbEqR0EtrxqeIm1VJzhE9AE-djsDFasYJJnO7Bo,9215
23
23
  gllm_core/schema/event.pyi,sha256=Yd74uSWhIO1lx0_p70rYt-LMz4FZHbbbqJP7xhVh_pY,1335
24
24
  gllm_core/schema/schema_generator.pyi,sha256=ToadC6UKEq35k32wUK1VaMKiICRtENXUYdAQOMlTg3U,1445
25
25
  gllm_core/schema/tool.pyi,sha256=T5TufJZPYUzYoSPZBX0FkqgZ9u03VAIsZdwvY1PS7nw,8848
26
- gllm_core/utils/__init__.pyi,sha256=KTUv1RiXQpr8Ef2owMYWUrAB7U_LpC9lTb0-rcHx0NM,1408
26
+ gllm_core/utils/__init__.pyi,sha256=XfPghmKqZ2h_bZzuawxYf6wa9Dp77JSWpd4_fiy2OYQ,1493
27
27
  gllm_core/utils/analyzer.pyi,sha256=E3xvelXssLGrKMRvHn_Ap-ao3dhCLPM-q2Pr1vHAdgw,4372
28
28
  gllm_core/utils/binary_handler_factory.pyi,sha256=Cpsv8gvCuD52c-q8sjZizSiRHV0h5sVdgYP9uMgKWbg,1717
29
29
  gllm_core/utils/chunk_metadata_merger.pyi,sha256=J1lHTFV-0IiC6xKzzC7x1D1wBoki249muEU2HrF6C58,2317
30
30
  gllm_core/utils/concurrency.pyi,sha256=S_B9BLhVzOOBANknZW0eVTKFHVjCYI3vD7zwLQfawvI,3941
31
- gllm_core/utils/event_formatter.pyi,sha256=ocQ_Ev_XorRhLzj0c2szlclz8V3_Ysbg6qHmjhmur3k,1375
31
+ gllm_core/utils/event_formatter.pyi,sha256=DH7uzItib_cBk9FthQAukNBqhVYzc-y6nR7wWVzLngs,1393
32
32
  gllm_core/utils/google_sheets.pyi,sha256=S3ArLRoWqGZpzqmuQ48xVVOZ9OjLILdD8Ez51QfufFM,847
33
- gllm_core/utils/imports.pyi,sha256=-KM0pyw7yFVCUZjHjoNBRFgEnI8hlr0pquKuhcA2X9M,2196
33
+ gllm_core/utils/imports.pyi,sha256=6U9UYV7QvVAOvfU4yuJnCcCnXXayLsCeJwK20U8sdpk,2196
34
34
  gllm_core/utils/logger_manager.pyi,sha256=uix04SafH9aXQSPiGNwleCiBRlTJfqZB3H8zxsJocuI,7130
35
35
  gllm_core/utils/main_method_resolver.pyi,sha256=dHozSqFMwCyVorQ0ZE9N-c2V4PkpF8FdU1VGGPvTjK4,2178
36
36
  gllm_core/utils/merger_method.pyi,sha256=JsgHnO47cqenqNxCrHqhAR-nnR_dEqE-7wprVrd8ZFg,1868
37
+ gllm_core/utils/repr.pyi,sha256=FMXXcQtpRKidf0ijPae6Dc21YI8TdWvgOaOWolsgJ8o,1126
37
38
  gllm_core/utils/retry.pyi,sha256=KxlPzURzZfCSgKC44v98nR2bqamzHqtbRuXLDEuX29c,1614
38
39
  gllm_core/utils/similarity.pyi,sha256=HmSxE5VfPwYZYih_bSIz8QRDbkouO_jij-FX6TSCEdM,439
39
40
  gllm_core/utils/validation.pyi,sha256=NFfyDCYsqHv44Z_5RqpSUEiuETpqH5Eoia5xwC4n1MU,938
40
41
  gllm_core.build/.gitignore,sha256=aEiIwOuxfzdCmLZe4oB1JsBmCUxwG8x-u-HBCV9JT8E,1
41
- gllm_core_binary-0.4.9.dist-info/METADATA,sha256=YAxXeFZXq0KOcOShZXy-sUNkXNH4hsPQ69hCjJ3X13A,4657
42
- gllm_core_binary-0.4.9.dist-info/WHEEL,sha256=O_u6PJIQ2pIcyIInxVQ9r-yArMuUZbBIaF1kpYVkYxA,96
43
- gllm_core_binary-0.4.9.dist-info/top_level.txt,sha256=UYoTGvK_Yec95-_QUuVCKEr6PUXb5Lc7Dr-x8SeX9uM,10
44
- gllm_core_binary-0.4.9.dist-info/RECORD,,
42
+ gllm_core_binary-0.4.10.dist-info/METADATA,sha256=ETa1kDrfSN12j4rvZlF0dP4_gB130Xc3CS8Uwf7S_W4,4658
43
+ gllm_core_binary-0.4.10.dist-info/WHEEL,sha256=O_u6PJIQ2pIcyIInxVQ9r-yArMuUZbBIaF1kpYVkYxA,96
44
+ gllm_core_binary-0.4.10.dist-info/top_level.txt,sha256=UYoTGvK_Yec95-_QUuVCKEr6PUXb5Lc7Dr-x8SeX9uM,10
45
+ gllm_core_binary-0.4.10.dist-info/RECORD,,