Skip to content

API Reference parrot_tools.scraping.plan_io

github-actions[bot] edited this page Dec 2, 2026 · 4 revisions

parrot_tools.scraping.plan_io

View source

Plan File I/O Helpers.

Async functions to save and load ScrapingPlan instances to/from disk, following the {plans_dir}/{domain}/{name}v{version}{fingerprint}.json layout.

Alias ScrapingPlan

Re-exported from parrot_tools.scraping.plan.ScrapingPlan.

Function is_within

Whether path resolves inside root (symlinks and .. followed).

is_within(path: Path, root: Path) -> bool

Parameter Type Default Description
path Path
root Path

Returns: bool

Function load_plan_from_disk

Load a ScrapingPlan from a JSON file on disk.

load_plan_from_disk(path: Path) -> ScrapingPlan

Parameter Type Default Description
path Path Path to the plan JSON file.

Returns: ScrapingPlan — Deserialized ScrapingPlan instance.

Raises:

  • FileNotFoundError — If the file does not exist.

Attribute logger

Function save_plan_to_disk

Save a ScrapingPlan to disk following the naming convention.

File layout: {plans_dir}/{domain}/{name}v{version}{fingerprint}.json Domain subdirectories are created automatically.

save_plan_to_disk(plan: ScrapingPlan, plans_dir: Path) -> Path

Parameter Type Default Description
plan ScrapingPlan The ScrapingPlan to save.
plans_dir Path Root directory for plan storage.

Returns: Path — Path to the saved file.

Architecture

Clients

Bots & Agents

Memory

Knowledge

Tools & Toolkits

Flows

Experts

Skills

Stores & Loaders

MCP & A2A

Server & APIs

Integrations

Outputs & A2UI

Prompts

Security

Operations

Migration

SDD Tooling

LLM Wiki

Deployment

Decisions

API Reference

Clone this wiki locally