Skip to content

Preemo-Inc/gradient-sdk-typescript-example

Repository files navigation

gradient-sdk-typescript-example

Quick example of how to use Gradient API with TypeScript.

Setup

The code relies on environment variables. They can be injected through dotenv by creating .env file in the current directory:

GRADIENT_ACCESS_TOKEN=...
GRADIENT_WORKSPACE_ID=...

Usage

  1. Clone this repo
  2. Run yarn install
  3. Run any of the following:
    • yarn blocks
    • yarn embeddings
    • yarn fine-tune
    • yarn guidance
    • yarn rag

Example

Alt Text