Apache Hamilton SDK for reading and writing to the Apache Hamilton backend APIs that support the UI.
Project description
Apache Hamilton UI SDK: Client Code & Related
Disclaimer
Apache Hamilton is an effort undergoing incubation at the Apache Software Foundation (ASF), sponsored by the Apache Incubator PMC.
Incubation is required of all newly accepted projects until a further review indicates that the infrastructure, communications, and decision making process have stabilized in a manner consistent with other successful ASF projects.
While incubation status is not necessarily a reflection of the completeness or stability of the code, it does indicate that the project has yet to be fully endorsed by the ASF.
Welcome to using the Apache Hamilton UI!
Here are instructions on how to get started with tracking, and managing your Apache Hamilton DAGs with the Apache Hamilton UI.
Getting Started
For the latest documentation, please consult our
Apache Hamilton documentation under Apache Hamilton UI.
For a quick overview of Apache Hamilton, we suggest tryhamilton.dev.
Using the HamiltonTracker
First, you'll need to install the Apache Hamilton SDK package. Assuming you're using pip, you can do this with:
# install the package & cli into your favorite python environment.
pip install "sf-hamilton[sdk]"
# And validate -- this should not error.
python -c "from hamilton_sdk import adapters"
Next, you'll need to modify your Apache Hamilton driver. You'll only need to use one line of code to replace your driver with ours:
from hamilton_sdk import adapters
from hamilton import driver
tracker = adapters.HamiltonTracker(
project_id=PROJECT_ID, # modify this as needed
username=YOUR_EMAIL, # modify this as needed
dag_name="my_version_of_the_dag",
tags={"environment": "DEV", "team": "MY_TEAM", "version": "X"}
)
dr = (
driver.Builder()
.with_config(your_config)
.with_modules(*your_modules)
.with_adapters(tracker)
.build()
)
# to run call .execute() or .materialize() on the driver
Project ID: You'll need a project ID. Create a project if you don't have one, and take the ID from that.
username: This is the email address you used to set up the Apache Hamilton UI.
dag_name: for a project, the DAG name is the top level way to group DAGs. E.g. ltv_model, us_sales, etc.
tags: these are optional are string key value paris. They allow you to filter and curate various DAG runs.
Then run Apache Hamilton as normal! Each DAG run will be tracked, and you'll have access to it in the Apache Hamilton UI. After spinning up the Apache Hamilton UI application, visit it to see your projects & DAGs.
License
The code here is licensed under the Apache 2.0 license. See the main repository LICENSE for details.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file apache_hamilton_sdk-0.9.0.dev0.tar.gz.
File metadata
- Download URL: apache_hamilton_sdk-0.9.0.dev0.tar.gz
- Upload date:
- Size: 253.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0388037ef703eb79d83e862c13ede66d5ff921ba9d12ce6943cb137a7ed79c10
|
|
| MD5 |
d2853d47392bf73840f73994279d0d31
|
|
| BLAKE2b-256 |
34a53d31034da3c4722e363f242c68d8f3f72c131ecaa701ed59a435eb97d785
|
File details
Details for the file apache_hamilton_sdk-0.9.0.dev0-py3-none-any.whl.
File metadata
- Download URL: apache_hamilton_sdk-0.9.0.dev0-py3-none-any.whl
- Upload date:
- Size: 284.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3788b09c20e60083fe478c6a54dc88c76a216c79575707320f1d28912ed4c221
|
|
| MD5 |
32c410b5c70cceb8906a404315081e1d
|
|
| BLAKE2b-256 |
926db7d2659790ca7a8b957c55e3703a259b27932f7911ad0167b506403b01cf
|