File size: 604 Bytes
e062359
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
from __future__ import annotations

from typing import Any
from typing_extensions import override

from ._proxy import LazyProxy


class ResourcesProxy(LazyProxy[Any]):
    """A proxy for the `anthropic.resources` module.

    This is used so that we can lazily import `anthropic.resources` only when
    needed *and* so that users can just import `anthropic` and reference `anthropic.resources`
    """

    @override
    def __load__(self) -> Any:
        import importlib

        mod = importlib.import_module("anthropic.resources")
        return mod


resources = ResourcesProxy().__as_proxied__()