Skip to main content

Package for Inferencing AI at DSC

Project description

aidsc

Small Python client for the Zeus control plane (vllm-orchestrator): typed language inference payloads, health checks, optional PAMD SSH when Zeus is not on localhost, and POST /api/requests.

Install (this monorepo)

From the repository root:

uv sync

aidsc is linked as an editable path dependency; then:

from aidsc import aidsc, LanguageArgs, LanguageInferenceRequest

Quick usage

from aidsc import aidsc, LanguageArgs, LanguageInferenceRequest

client = aidsc()  # reads .env via python-dotenv
client.ensure_ready()

req = LanguageInferenceRequest(
    args=LanguageArgs(
        model="gpt-oss-20b",
        questions=["Answer in one sentence: what is 2+2?"],
    ),
    max_context_length=8192,
    max_server_uptime=604800,
    max_new_tokens=512,
    total_concurrent_models=1,
    max_num_seqs=8,
)
out = client.infer(req, server=117)  # pin class117.sc.fsu.edu
print(out)

How this relates to Zeus

  1. Your code builds a LanguageInferenceRequest and calls aidsc.infer, which sends JSON to POST /api/requests on Zeus (see app.py).
  2. Zeus validates a ZeusRequest, picks a lab machine (or honors server), and drives the receiver on that host over SSH (see utils/ssh/orchestrator.py).
  3. GET /api/zeus-health on Zeus returns {"healthy": true} for local liveness only.

Environment variables

Variable Purpose
aidsc_ZEUS_LOCAL_URL Default http://127.0.0.1:32553 — Zeus when you are on the Zeus host.
aidsc_ZEUS_REMOTE_URL Default http://144.174.11.196:32553 — Zeus URL as reachable from PAMD (used when localhost is down).
aidsc_SSH_PAMD Full SSH prefix, e.g. ssh user@pamd.sc.fsu.edu, used when localhost health fails.

Interactive bootstrap (writes .env and ensures .gitignore contains .env when in a git repo):

aidsc().setup_interactive()

Payload shape

Matches data/sample_payload.json: type is always "language" for now; args holds model and questions. These map to Zeus POST /api/requests fields:

Field Zeus JSON key Default
max_context_length max_context_length 8192
max_model_len (alias for max_context_length )
max_server_uptime max_server_uptime 604800 (7 days)
max_new_tokens max_new_tokens 512
total_concurrent_models total_concurrent_models 1
max_num_seqs max_num_seqs 8

aidsc.infer(..., max_new_tokens=...) still overrides the request’s max_new_tokens when passed.

Layout

Path Role
src/aidsc/client.py aidsc, mapping to Zeus JSON
src/aidsc/models.py Pydantic payload models
src/aidsc/zeus_client.py HTTP health + /api/requests
src/aidsc/connectivity.py Localhost vs PAMD+remote health
src/aidsc/env_bootstrap.py .env load, .gitignore for .env

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

aidsc-0.1.0.tar.gz (6.7 kB view details)

Uploaded Source

Built Distribution

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

aidsc-0.1.0-py3-none-any.whl (9.1 kB view details)

Uploaded Python 3

File details

Details for the file aidsc-0.1.0.tar.gz.

File metadata

  • Download URL: aidsc-0.1.0.tar.gz
  • Upload date:
  • Size: 6.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.23

File hashes

Hashes for aidsc-0.1.0.tar.gz
Algorithm Hash digest
SHA256 6869e0efac7b5b730ef4e73409425144ae45bfe2b9d1e83bd24445d607ad0f23
MD5 680a7133074ee26c92fe24888fa29cff
BLAKE2b-256 b94deaf165091c7ba017f18456782739168fbe5580a9c4732a2296bb3bad7ba5

See more details on using hashes here.

File details

Details for the file aidsc-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: aidsc-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 9.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.23

File hashes

Hashes for aidsc-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ead335feacc4ded44819e24ada5d9c5be4c9263fb6974145fdab32ad980ad446
MD5 323cb008c56c4919238e856f53ccafa4
BLAKE2b-256 848b6b1b151f8dedff200a09baae2dfec2e77bd604b3c59a8e07e21752ec1a40

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