Skip to main content

A unified multimodal model evaluation tracking and engineering report engine.

Project description

NoA Python SDK API Reference Documentation

This document provides technical reference details for the classes, methods, parameters, and streaming response objects available within the krysta client library.


Core Class Architecture

NoA Class

The main client manager used to initialize connections and manage state lifecycle pipes with your remote execution infrastructure gateway.

from krysta.noa import Noa

Class Constructor Matrix

Noa()
  • Parameters:
    • gateway_url (str, Optional): The network address of your custom backend execution gateway. If omitted, the SDK connects automatically to the hosted Krysta live cloud server.

Context Manager Methods

The client class fully implements the standard asynchronous context manager layout (__aenter__ / __aexit__) to automatically handle network streams, channel allocations, and memory resource cleanups safely.

# Connects to the cloud automatically with zero config
async with Noa() as client:
    # Execution resources are automatically allocated here
    pass
# Connection pipes are safely destroyed here

Method Reference Maps

execute()

Initiates an asynchronous Server-Sent Events (SSE) background task worker thread to evaluate a raw source code string.

Method Definition Syntax

def execute(
    language: str, 
    code: str, 
    timeout_ms: int = 5000
) -> AsyncIterator[dict]:

Input Arguments Block

  • language (str, Required): The programming compilation runner target environment to spawn inside the isolated cluster node. Supported strings:
    • "python"
    • "javascript"
  • code (str, Required): The uncompiled text string payload containing the raw source code script to evaluate inside the container pool.
  • timeout_ms (int, Optional): The strict maximum allowed execution time window in milliseconds before the watchdog thread hard-kills (SIGKILL) the task runner. Default fallback threshold value: 5000.

Return Type Value

  • Returns an AsyncIterator[dict] stream generator object. You must consume this data payload frame-by-frame using an async for loop layout block.

Stream Event Response Payload Schema

Every data unit emitted from the async iterator returns a structured Python dict map object containing the following token parameters:

{
  "type": "system" | "stdout" | "stderr" | "rules" | "done" | "error",
  "text": "string" | null,
  "timestamp": integer
}

Event Parameter Types Definition Matrix

1. type: "system"

Emitted immediately when the gateway server begins allocating memory allocations or scheduling task execution queues.

  • Text Contents: Standard tracking message flags (e.g., "EXECUTION_STARTED").

2. type: "stdout"

Emitted instantly whenever the sandboxed script writes characters to the standard console system output.

  • Text Contents: The raw printed string text data.

3. type: "stderr"

Emitted instantly when unhandled runtime errors, system exceptions, or line code tracebacks occur inside the isolated runner.

  • Text Contents: Standard multiline traceback exception information text.

4. type: "rules"

Emitted near task termination. Contains a serialized JSON string listing static metric quality scores and evaluation check markers.

  • Text Contents Schema:
    "[{\"rule\": \"ExitCodeZeroRule\", \"result\": \"PASS\" | \"FAIL\", \"reason\": \"...\"}]"
    

5. type: "done"

Emitted when the execution lifecycle pipeline completes its loop naturally and closes down successfully.

  • Text Contents: null

6. type: "error"

Emitted if a network drop occurs, or if the server cannot complete an internal spawn routing operation.

  • Text Contents: Detailed platform failure tracking notes (e.g., "Job failed during execution").

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

krysta-1.0.7.tar.gz (12.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

krysta-1.0.7-py3-none-any.whl (14.0 kB view details)

Uploaded Python 3

File details

Details for the file krysta-1.0.7.tar.gz.

File metadata

  • Download URL: krysta-1.0.7.tar.gz
  • Upload date:
  • Size: 12.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.4

File hashes

Hashes for krysta-1.0.7.tar.gz
Algorithm Hash digest
SHA256 f76025a0a00087d0b8faed15dde9323cdf34fc8b1cc3aeb9cb05026185b3d053
MD5 cf8d27f15dd57d8df553c8b401bac517
BLAKE2b-256 b91fe4d567dd1bd284cd25a8fc2375fe4c1ab954d0be9c5c9470a290ae5f0a5f

See more details on using hashes here.

File details

Details for the file krysta-1.0.7-py3-none-any.whl.

File metadata

  • Download URL: krysta-1.0.7-py3-none-any.whl
  • Upload date:
  • Size: 14.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.4

File hashes

Hashes for krysta-1.0.7-py3-none-any.whl
Algorithm Hash digest
SHA256 edac23759374ba3da8de467057a09652c02e911815104514821ee31303e31709
MD5 5732f66fb3874e46d582a4c4d9b35628
BLAKE2b-256 51ae9c4ba5ea43d5bb7ec0bcc9a1cfa695a2bf5a4dc98f58edadc86f2f2a631e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page