Foundry Platform SDK

repository·develop·Indexed 41 days ago

https://github.com/palantir/foundry-platform-python

The official Python library for the Foundry API, automatically generated from the API specification. It enables programmatic interaction with the Foundry platform to manage datasets, branches, and ontological metadata. The SDK supports multiple API versions (latest is v2), provides both synchronous and asynchronous clients (beta), and includes built-in support for converting tabular data to PyArrow, Pandas, Polars, and DuckDB DataFrames.

Tokens
565.4K
Snippets
1.5K
Records
2.3K
Agent score
48%

What's inside Foundry Platform SDK

  1. Manage Schedules via the Orchestration API

    develop

    The Schedule API allows you to create, retrieve, delete, and control the execution of schedules in Foundry.

    Available Methods

    • create: Creates a new Schedule. (Public Beta)
    • delete: Deletes a Schedule by its RID. (Stable)
    • get: Retrieves a specific Schedule by its RID. (Public Beta)
    • get_affected_resources: Retrieves resources affected by a specific Schedule. (Public Beta)
    • get_batch: Fetches multiple schedules in a single request (max 1000). (Public Beta)
    • pause: Pauses a Schedule. (Stable)
    • replace: Replaces an existing Schedule. (Public Beta)
    • run: Manually triggers a Schedule run. (Stable)
    • runs: Retrieves the run history for a Schedule. (Stable)
    • unpause: Resumes a paused Schedule. (Stable)
  2. What is a FoundryWorker and when to use it

    develop
    A FoundryWorker is a connection type used to run capabilities directly within Foundry. It is the preferred method for establishing connections because it leverages Foundry's containerized and scalable job execution environment. Using a FoundryWorker provides improved stability and eliminates the maintenance overhead required by managing external agents.
  3. Use SearchCheckpointRecordsAndFilter to combine checkpoint filters

    develop

    The SearchCheckpointRecordsAndFilter model is used to perform a logical AND conjunction of multiple checkpoint record filters. When searching for checkpoint records, you can use this model to ensure that all specified criteria in the filters list are met simultaneously.

    Properties

    NameTypeRequiredDescription
    filtersList[SearchCheckpointRecordsFilter]YesA list of individual filters to be combined using logical AND.
    typeLiteral["and"]YesThe logical operator type, which must be set to "and" for this model.
  4. Use ApiNameLocatorWrapper to locate models by API name

    develop

    The ApiNameLocatorWrapper is a specialized model locator used to find language models based on their specific API name. When constructing a locator object, you must provide the api_name and set the type to the literal value "apiName".

    # Example structure of an ApiNameLocatorWrapper
    locator = ApiNameLocatorWrapper(
        api_name="your_model_api_name",
        type="apiName"
    )