Spaces:
Sleeping
Sleeping
Download agents/context.py from DerXanity/farient-deckcheck: direct link, hf CLI and curl.
- Browser
- Download file 884 Bytes
-
https://huggingface.co/spaces/DerXanity/farient-deckcheck/resolve/main/agents/context.py
- Command line
-
hf download hf://spaces/DerXanity/farient-deckcheck/agents/context.py
-
curl -L -o context.py https://huggingface.co/spaces/DerXanity/farient-deckcheck/resolve/main/agents/context.py
884 Bytes
| """AuditContext — shared state passed to agent tools via RunContextWrapper.""" | |
| from __future__ import annotations | |
| from dataclasses import dataclass | |
| from pathlib import Path | |
| from rubric.loader import Rubric | |
| from schemas.parsed import ParsedDeck | |
| from services.renderer import RenderResult | |
| class AuditContext: | |
| """Shared, read-only context passed to every agent tool via RunContextWrapper[AuditContext]. | |
| Attributes | |
| ---------- | |
| parsed_deck: | |
| Fully parsed PPTX data (shapes, text, notes, EMU positions). | |
| render_result: | |
| Output of ``render_deck``; may be ``skipped=True`` if LibreOffice is unavailable. | |
| rubric: | |
| Loaded brand-rules rubric (Pydantic-validated). | |
| out_dir: | |
| Directory where rendered PNGs are stored. | |
| """ | |
| parsed_deck: ParsedDeck | |
| render_result: RenderResult | |
| rubric: Rubric | |
| out_dir: Path | |