Squash-merge lib-standardisation: adopt repo standards across packaging, tooling, docs, and CI. - standardize pyproject.toml (canonical packaging, lint config, extras, GSDFC pydoclint) - add py.typed marker, modernize type hints and Google-style docstrings - nest generated docs under docs/lib and docs/mcp; add hand-written wiki - adopt standard Type A PyPI CI pipeline (tag==version guard + quality gate) - promote generated CHANGELOG.md; bump version to 0.0.3
25 lines
634 B
Python
25 lines
634 B
Python
from collections.abc import Mapping
|
|
from enum import Enum
|
|
from typing import Any
|
|
|
|
class ContentType(str, Enum):
|
|
HTML = "text/html"
|
|
PDF = "application/pdf"
|
|
XLSX = "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"
|
|
CSV = "text/csv"
|
|
JSON = "application/json"
|
|
XML = "application/xml"
|
|
|
|
class Content:
|
|
raw: bytes
|
|
source: str
|
|
content_type: ContentType | None
|
|
metadata: Mapping[str, Any] | None
|
|
def __init__(
|
|
self,
|
|
raw: bytes,
|
|
source: str,
|
|
content_type: ContentType | None = ...,
|
|
metadata: Mapping[str, Any] | None = ...,
|
|
) -> None: ...
|