Getting Started

This guide will help you get up and running with the Perseus client.

Installation

You can install the SDK using pip:

pip install perseus-client==1.0.0-rc.2

Quick Start

To begin using the SDK, you’ll need a Lettria API key. You can generate one from the Perseus console.

Configuration

The SDK can be configured via environment variables. The PerseusClient will automatically load them. You can place them in a .env file in your project root. For a complete list of configuration options, see the Configuration documentation..

VariableDescriptionRequired
LETTRIA_API_KEYYour unique API key for the Lettria API.Yes

Example: Build a Graph

This example shows how to build a graph from a text file. More about the build_graph method here.

from perseus_client.client import PerseusClient

with PerseusClient() as client:
    client.build_graph(
        file_path="assets/pizza.txt",
    )