Skip to content

Commit 662af37

Browse files
committed
chore: bump hatchet and improve docs
1 parent f33ecaf commit 662af37

11 files changed

Lines changed: 1089 additions & 19 deletions

File tree

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,9 +73,9 @@ This is the initial data that triggers the workflow. You can modify this to test
7373

7474
These are the outputs from preceding steps in the workflow. You can view and modify these to understand how data flows through and affects subsequent steps.
7575

76-
###### Overrides
76+
###### Playground
7777

78-
Within each step of your workflow, there is a `context` parameter. This parameter features a unique method called `overrides`, which accepts two arguments: a name (as a string) and a value (which must be a primitive data type). This functionality is designed to dynamically adjust certain aspects of your workflow on the fly. When you execute a step in the Playground, Hatchet recognizes any `overrides` you've implemented, enabling you to modify them directly. This flexibility is especially useful for fine-tuning specific parameters, such as adjusting prompt instructions or other configurations.
78+
Within each step of your workflow, there is a `context` parameter. This parameter features a unique method called `playground`, which accepts two arguments: a name (as a string) and a value (which must be a primitive data type). This functionality is designed to dynamically adjust certain aspects of your workflow on the fly. When you execute a step in the Playground, Hatchet recognizes any `playground` you've implemented, enabling you to modify them directly. This flexibility is especially useful for fine-tuning specific parameters, such as adjusting prompt instructions or other configurations.
7979

8080
###### Debugging
8181

fast-api-react/README.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,16 +8,17 @@ Before running this project, make sure you have the following:
88

99
1. Python 3.7 or higher installed on your machine.
1010
2. Poetry package manager installed. You can install it by running `pip install poetry`, or by following instructions in the [Poetry Docs](https://python-poetry.org/docs/#installation)
11-
3. Clone this repository to your local machine.
12-
4. (Optional) If you would like to run the example frontend, Node which can be installed from the [node website](https://nodejs.org/en/download)
11+
3. (Optional) If you would like to run the example frontend, Node which can be installed from the [node website](https://nodejs.org/en/download)
1312

1413
## Setup
1514

16-
1. Create a `.env` file in the `./backend` directory and set the required environment variables.
15+
1. Create a `.env` file in the `./backend` directory and set the required environment variables. This requires the `HATCHET_CLIENT_TOKEN` variable created in the [Getting Started README](/README.md). You will also need, a `OPENAI_API_KEY` which can be created on the [OpenAI Website](https://help.openai.com/en/articles/4936850-where-do-i-find-my-openai-api-key).
1716

18-
This project requires the `HATCHET_CLIENT_TOKEN` variable created in the [Getting Started README](/README.md).
19-
20-
You will also need, a `OPENAI_API_KEY` which can be created on the [OpenAI Website](https://help.openai.com/en/articles/4936850-where-do-i-find-my-openai-api-key).
17+
```
18+
HATCHET_CLIENT_TLS_STRATEGY=none
19+
HATCHET_CLIENT_TOKEN="<token>"
20+
OPENAI_API_KEY="<openai-key>"
21+
```
2122

2223
2. Open a terminal and navigate to the project root directory (`/fast-api-react`).
2324

fast-api-react/backend/poetry.lock

Lines changed: 5 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

fast-api-react/backend/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ openai = "^1.11.0"
1818
beautifulsoup4 = "^4.12.3"
1919
requests = "^2.31.0"
2020
urllib3 = "1.26.15"
21-
hatchet-sdk = "0.10.2"
21+
hatchet-sdk = "0.10.3"
2222

2323
[build-system]
2424
requires = ["poetry-core"]

simple-examples/README.md

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# Hatchet FastAPI Example
2+
3+
This is an example project demonstrating how to run a simple Hatchet worker.
4+
5+
## Prerequisites
6+
7+
Before running this project, make sure you have the following:
8+
9+
1. Python 3.7 or higher installed on your machine.
10+
2. Poetry package manager installed. You can install it by running `pip install poetry`, or by following instructions in the [Poetry Docs](https://python-poetry.org/docs/#installation)
11+
12+
## Setup
13+
14+
1. Create a `.env` file in this directory and set the required environment variables. This requires the `HATCHET_CLIENT_TOKEN` variable created in the [Getting Started README](/README.md).
15+
16+
```
17+
HATCHET_CLIENT_TLS_STRATEGY=none
18+
HATCHET_CLIENT_TOKEN="<token>"
19+
```
20+
21+
2. Open a terminal and navigate to the project root directory (`/simple-examples`).
22+
23+
3. Run the following command to install the project dependencies:
24+
25+
```shell
26+
poetry install
27+
```
28+
29+
## Running the Hatchet Worker
30+
31+
In a separate terminal, start the the Hatchet worker by running the following command:
32+
33+
```shell
34+
poetry run hatchet
35+
```
36+
37+
You can then navigate to the workflow in the Hatchet dashboard to view the structure of this workflow.

0 commit comments

Comments
 (0)