MaxComputeAPIWrapper#

class langchain_community.utilities.max_compute.MaxComputeAPIWrapper(client: ODPS)[source]#

Interface for querying Alibaba Cloud MaxCompute tables.

Initialize MaxCompute document loader.

Parameters:

client (ODPS) – odps.ODPS MaxCompute client object.

Methods

__init__(client)

Initialize MaxCompute document loader.

from_params(endpoint,Β project,Β *[,Β ...])

Convenience constructor that builds the odsp.ODPS MaxCompute client from

lazy_query(query)

query(query)

__init__(client: ODPS)[source]#

Initialize MaxCompute document loader.

Parameters:

client (ODPS) – odps.ODPS MaxCompute client object.

classmethod from_params(endpoint: str, project: str, *, access_id: str | None = None, secret_access_key: str | None = None) β†’ MaxComputeAPIWrapper[source]#
Convenience constructor that builds the odsp.ODPS MaxCompute client from

given parameters.

Parameters:
  • endpoint (str) – MaxCompute endpoint.

  • project (str) – A project is a basic organizational unit of MaxCompute, which is similar to a database.

  • access_id (str | None) – MaxCompute access ID. Should be passed in directly or set as the environment variable MAX_COMPUTE_ACCESS_ID.

  • secret_access_key (str | None) – MaxCompute secret access key. Should be passed in directly or set as the environment variable MAX_COMPUTE_SECRET_ACCESS_KEY.

Return type:

MaxComputeAPIWrapper

lazy_query(query: str) β†’ Iterator[dict][source]#
Parameters:

query (str)

Return type:

Iterator[dict]

query(query: str) β†’ List[dict][source]#
Parameters:

query (str)

Return type:

List[dict]