SDK for interacting with Orca Services
Project description
OrcaSDK
OrcaSDK is a Python library for building and using retrieval-augmented models with OrcaCloud. It enables you to create, deploy, and maintain models that can adapt to changing circumstances without retraining by accessing external data called "memories."
Documentation
You can find the documentation for all things Orca at docs.orcadb.ai. This includes tutorials, how-to guides, and the full interface reference for OrcaSDK.
Features
- Labeled Memorysets: Store and manage labeled examples that your models can use to guide predictions
- Classification Models: Build retrieval-augmented classification models that adapt to new data without retraining
- Embedding Models: Use pre-trained or fine-tuned embedding models to represent your data
- Telemetry: Collect feedback and monitor memory usage to optimize model performance
- Datasources: Easily ingest data from various sources into your memorysets
Installation
OrcaSDK is compatible with Python 3.10 or higher and is available on PyPI. You can install it with your favorite python package manager:
- Pip:
pip install orca_sdk - Conda:
conda install orca_sdk - Poetry:
poetry add orca_sdk
Quick Start
from dotenv import load_dotenv
from orca_sdk import OrcaCredentials, LabeledMemoryset, ClassificationModel
# Load your API key from environment variables
load_dotenv()
assert OrcaCredentials.is_authenticated()
# Create a labeled memoryset
memoryset = LabeledMemoryset.from_disk("my_memoryset", "./data.jsonl")
# Create a classification model using the memoryset
model = ClassificationModel("my_model", memoryset)
# Make predictions
prediction = model.predict("my input")
# Get Action Recommendation
action, rationale = prediction.recommend_action()
print(f"Recommended action: {action}")
print(f"Rationale: {rationale}")
# Generate and add synthetic memory suggestions
if action == "add_memories":
suggestions = prediction.generate_memory_suggestions(num_memories=3)
# Review suggestions
for suggestion in suggestions:
print(f"Suggested: '{suggestion['value']}' -> {suggestion['label']}")
# Add suggestions to memoryset
model.memoryset.insert(suggestions)
print(f"Added {len(suggestions)} new memories to improve model performance!")
For a more detailed walkthrough, check out our Quick Start Guide.
Support
If you have any questions, please reach out to us at support@orcadb.ai.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file orca_sdk-0.1.17.tar.gz.
File metadata
- Download URL: orca_sdk-0.1.17.tar.gz
- Upload date:
- Size: 148.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8516019c03cfde167e1adc7afc9f36be152e63d12781abfa1c15e7e20c71696b
|
|
| MD5 |
169918ba3a6454cde35e535f9b6fd7e2
|
|
| BLAKE2b-256 |
c61692327f2ab60fe3d7a915db0c8bb251bdca8e1543e648562e887200def5ae
|
Provenance
The following attestation bundles were made for orca_sdk-0.1.17.tar.gz:
Publisher:
orca-sdk-release.yml on OrcaDB/orca
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
orca_sdk-0.1.17.tar.gz -
Subject digest:
8516019c03cfde167e1adc7afc9f36be152e63d12781abfa1c15e7e20c71696b - Sigstore transparency entry: 1217909453
- Sigstore integration time:
-
Permalink:
OrcaDB/orca@a4ad3713ad17a6c7c36e4d54e95d1a26afb5b15e -
Branch / Tag:
refs/heads/main - Owner: https://github.com/OrcaDB
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
orca-sdk-release.yml@a4ad3713ad17a6c7c36e4d54e95d1a26afb5b15e -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file orca_sdk-0.1.17-py3-none-any.whl.
File metadata
- Download URL: orca_sdk-0.1.17-py3-none-any.whl
- Upload date:
- Size: 161.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5658f5fe75ffef546c016eccb0f2b0b8262720f11e71c9085bbb2e2325de7161
|
|
| MD5 |
f28bfe541caf21e253898db7446106c4
|
|
| BLAKE2b-256 |
2e490b190aab478f6a0eddf498f76bdd0d4232c1a34d61cd6f03721778a63f24
|
Provenance
The following attestation bundles were made for orca_sdk-0.1.17-py3-none-any.whl:
Publisher:
orca-sdk-release.yml on OrcaDB/orca
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
orca_sdk-0.1.17-py3-none-any.whl -
Subject digest:
5658f5fe75ffef546c016eccb0f2b0b8262720f11e71c9085bbb2e2325de7161 - Sigstore transparency entry: 1217909455
- Sigstore integration time:
-
Permalink:
OrcaDB/orca@a4ad3713ad17a6c7c36e4d54e95d1a26afb5b15e -
Branch / Tag:
refs/heads/main - Owner: https://github.com/OrcaDB
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
orca-sdk-release.yml@a4ad3713ad17a6c7c36e4d54e95d1a26afb5b15e -
Trigger Event:
workflow_dispatch
-
Statement type: