mirror of
https://github.com/Skyvern-AI/skyvern.git
synced 2025-09-15 01:39:41 +00:00
Add PDF Parser Block (#1600)
This commit is contained in:
parent
8f3941b6b5
commit
1796af6df9
6 changed files with 143 additions and 2 deletions
|
@ -215,6 +215,13 @@ class FileParserBlockYAML(BlockYAML):
|
|||
file_type: FileType
|
||||
|
||||
|
||||
class PDFParserBlockYAML(BlockYAML):
|
||||
block_type: Literal[BlockType.PDF_PARSER] = BlockType.PDF_PARSER # type: ignore
|
||||
|
||||
file_url: str
|
||||
json_schema: dict[str, Any] | None = None
|
||||
|
||||
|
||||
class ValidationBlockYAML(BlockYAML):
|
||||
block_type: Literal[BlockType.VALIDATION] = BlockType.VALIDATION # type: ignore
|
||||
|
||||
|
@ -343,6 +350,7 @@ BLOCK_YAML_SUBCLASSES = (
|
|||
| WaitBlockYAML
|
||||
| FileDownloadBlockYAML
|
||||
| UrlBlockYAML
|
||||
| PDFParserBlockYAML
|
||||
)
|
||||
BLOCK_YAML_TYPES = Annotated[BLOCK_YAML_SUBCLASSES, Field(discriminator="block_type")]
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue