Skip to main content

WaveAssist Python SDK for storing and retrieving structured data

Project description

WaveAssist Python SDK 🌊

WaveAssist makes it simple to store and retrieve data in your WaveAssist.io workflows.


✨ Features

  • 🔐 Simple init() to connect with your project
  • 📦 Store and retrieve data (DataFrames, JSON, or strings)
  • 🧠 LLM-friendly function names (init, store_data, fetch_data)
  • 📁 Auto-serialization for common Python objects
  • ✅ Ready for integration with any workflow or script

🚀 Getting Started

1. Install

pip install waveassist

2. Initialize the SDK

import waveassist

waveassist.init(
    token="your-api-token-or-uid",
    project_key="your-project-id",
    environment_key="optional-env"  # defaults to <project_key>_default
)

3. Store Data

🧾 Store a string

waveassist.store_data("welcome_message", "Hello, world!")

📊 Store a DataFrame

import pandas as pd

df = pd.DataFrame({"name": ["Alice", "Bob"], "score": [95, 88]})
waveassist.store_data("user_scores", df)

🧠 Store JSON/dict/array

profile = {"name": "Alice", "age": 30}
waveassist.store_data("profile_data", profile)

4. Fetch Data

result = waveassist.fetch_data("user_scores")

# Will return:
# - A DataFrame (if stored as one)
# - A dict/list (if stored as JSON)
# - A string (if stored as text)

🧪 Running Tests

If you’re not using pytest, just run the test script directly:

python tests/run_tests.py

✅ Includes tests for:

  • String roundtrip
  • JSON/dict roundtrip
  • DataFrame roundtrip
  • Error case when init() is missing

🛠 Project Structure

WaveAssist/
├── waveassist/
│   ├── __init__.py          # init(), store_data(), fetch_data()
│   ├── _config.py           # Global config vars
│   └── ...
├── tests/
│   └── run_tests.py         # Manual test runner

📌 Notes

  • Data is stored in your backend (MongoDB) as serialized strings (JSON, CSV, etc.)
  • store_data() auto-detects the type of the object and serializes accordingly
  • fetch_data() deserializes and returns the proper Python object

🤝 Contributing

Want to add new features/formats or integrations? PRs welcome!


🧠 Example Use Case

import waveassist
waveassist.init("my-token", "project123")

# Store GitHub PR data from an automation job
waveassist.store_data("latest_pr", {
    "title": "Fix bug in auth",
    "author": "alice",
    "status": "open"
})

# Later, fetch it for processing
pr = waveassist.fetch_data("latest_pr")
print(pr["title"])

📬 Contact

Need help or have feedback? Reach out at [connect@waveassist.io] or open an issue.


© 2025 WaveAssist

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

waveassist-0.0.4.tar.gz (4.8 kB view details)

Uploaded Source

Built Distribution

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

waveassist-0.0.4-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file waveassist-0.0.4.tar.gz.

File metadata

  • Download URL: waveassist-0.0.4.tar.gz
  • Upload date:
  • Size: 4.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for waveassist-0.0.4.tar.gz
Algorithm Hash digest
SHA256 c73c2893577416fe0242ec3941be4d9e6570d1f32a4181f0fc8e86e54ef598e5
MD5 8a301c0488612f6bca4ff08f907a1136
BLAKE2b-256 868a7cf3de37a583dfc50f627a8e4b6b046c630e2276c72702aba0376aa5f546

See more details on using hashes here.

Provenance

The following attestation bundles were made for waveassist-0.0.4.tar.gz:

Publisher: python-publish.yml on WaveAssist/waveassist

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file waveassist-0.0.4-py3-none-any.whl.

File metadata

  • Download URL: waveassist-0.0.4-py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for waveassist-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 8cd8abcbb18f6e99625b6964106137ab02189aeda65b3a582b1c725d66c71940
MD5 98dfe08203c27ad09c9702c19b5e6679
BLAKE2b-256 eda1e4a177df6ebfb785fcdb48eae344d07dc32ca724225d9f3dee59b5c62b2c

See more details on using hashes here.

Provenance

The following attestation bundles were made for waveassist-0.0.4-py3-none-any.whl:

Publisher: python-publish.yml on WaveAssist/waveassist

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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