Qwak Core

raw JSON →
0.7.64 verified Sat May 09 auth: no python

Qwak Core provides the foundational objects and communication tools for interacting with the Qwak MLOps platform (version 0.7.64). It includes model inference clients, authentication utilities, and other core abstractions. The library is released frequently, with multiple releases per month.

pip install qwak-core
error ModuleNotFoundError: No module named 'qwak'
cause Tried to import from the top-level 'qwak' package instead of 'qwak-core'.
fix
Run 'pip install qwak-core' and then use 'from qwak.core...' imports.
error ImportError: cannot import name 'QwakInferenceClient' from 'qwak'
cause Incorrect import path - QwakInferenceClient is in qwak.core.inference.
fix
Use 'from qwak.core.inference import QwakInferenceClient'.
error ValueError: Invalid API key
cause The provided API key is either missing, malformed, or not authorized.
fix
Check that the API key is set correctly, either via 'QWAK_API_KEY' environment variable or passed as a string to QwakAuth.
breaking Python version requirement changed: qwak-core 0.7.x requires Python >=3.9,<3.12. Python 3.6 and 3.7 are not supported.
fix Use Python 3.9, 3.10, or 3.11.
gotcha All imports must come from submodules under 'qwak.core'. Direct imports like 'from qwak import ...' will fail.
fix Use 'from qwak.core.{submodule} import {class}'.
deprecated QwakInferenceClient is actively maintained but some older methods like 'predict_async' may be deprecated. Always check the latest docs for method availability.
fix Refer to official documentation for current API.
gotcha API key authentication is required for most operations. Missing or invalid API key will raise an authentication error.
fix Set the QWAK_API_KEY environment variable or pass it directly to QwakAuth.

Initialize authentication and inference client, then run a prediction.

from qwak.core.inference import QwakInferenceClient
from qwak.core.auth import QwakAuth

api_key = os.environ.get('QWAK_API_KEY', '')
auth = QwakAuth(api_key=api_key)
client = QwakInferenceClient(auth=auth)
response = client.predict(model_id='my-model', input_data={'feature1': 1.0})
print(response)