Compare commits

...

2 Commits

Author SHA1 Message Date
Logan Markewich 12537dcec3 deprecate split-by-page 2025-08-18 12:57:27 -06:00
Logan Markewich 90d30cb284 Deprecate load_data/aload_data API 2025-08-18 12:48:49 -06:00
3 changed files with 25 additions and 4 deletions
+22 -1
View File
@@ -5,6 +5,7 @@ import time
import warnings
from contextlib import asynccontextmanager
from copy import deepcopy
from deprecated import deprecated
from enum import Enum
from io import BufferedIOBase
from pathlib import Path, PurePath, PurePosixPath
@@ -166,7 +167,8 @@ class LlamaParse(BasePydanticReader):
)
split_by_page: bool = Field(
default=True,
description="Whether to split by page using the page separator",
description="(Deprecated, use `result.get_x_documents(split_by_page=True)` instead) Whether to split by page using the page separator",
deprecated=True,
)
verbose: bool = Field(
default=True, description="Whether to print the progress of the parsing."
@@ -559,6 +561,11 @@ class LlamaParse(BasePydanticReader):
+ f".\n{suggestions_str}",
)
if "split_by_page" in data:
warnings.warn(
"The `split_by_page` parameter is deprecated. Use `result.get_x_documents(split_by_page=True)` instead.",
)
return data
@field_validator("api_key", mode="before", check_fields=True)
@@ -1270,6 +1277,13 @@ class LlamaParse(BasePydanticReader):
else:
raise e
@deprecated(
reason=(
"Use the `.aparse()` method instead. See the docs for more information on usage: "
"https://github.com/run-llama/llama_cloud_services/blob/main/parse.md#python-usage"
),
version="0.6.62",
)
async def aload_data(
self,
file_path: Union[List[FileInput], FileInput],
@@ -1316,6 +1330,13 @@ class LlamaParse(BasePydanticReader):
"The input file_path must be a string or a list of strings."
)
@deprecated(
reason=(
"Use the `.parse()` method instead. See the docs for more information on usage: "
"https://github.com/run-llama/llama_cloud_services/blob/main/parse.md#python-usage"
),
version="0.6.62",
)
def load_data(
self,
file_path: Union[List[FileInput], FileInput],
+2 -2
View File
@@ -11,13 +11,13 @@ dev = [
[project]
name = "llama-parse"
version = "0.6.60"
version = "0.6.62"
description = "Parse files into RAG-Optimized formats."
authors = [{name = "Logan Markewich", email = "logan@llamaindex.ai"}]
requires-python = ">=3.9,<4.0"
readme = "README.md"
license = "MIT"
dependencies = ["llama-cloud-services>=0.6.60"]
dependencies = ["llama-cloud-services>=0.6.62"]
[project.scripts]
llama-parse = "llama_parse.cli.main:parse"
+1 -1
View File
@@ -19,7 +19,7 @@ dev = [
[project]
name = "llama-cloud-services"
version = "0.6.61"
version = "0.6.62"
description = "Tailored SDK clients for LlamaCloud services."
authors = [{name = "Logan Markewich", email = "logan@runllama.ai"}]
requires-python = ">=3.9,<4.0"