UTSS - Universal Trading Strategy Schema
A comprehensive, composable schema for expressing any trading strategy.
Installation
pip install utss
Quick Start
from utss import validate_yaml, Strategy
# Load and validate a strategy from YAML
strategy = validate_yaml("""
info:
id: rsi-reversal
name: RSI Reversal Strategy
version: "1.0"
universe:
type: static
symbols: ["AAPL", "GOOGL"]
rules:
- name: buy-oversold
when:
type: comparison
left:
type: indicator
indicator: RSI
params:
period: 14
operator: "<"
right:
type: constant
value: 30
then:
type: trade
direction: buy
sizing:
type: percent_of_equity
percent: 10
""")
print(f"Strategy: {strategy.info.name}")
print(f"Universe: {strategy.universe}")
print(f"Rules: {len(strategy.rules)}")
Features
- LLM-friendly: Predictable structure, clear type discriminators
- Composable: Signals → Conditions → Rules → Strategy
- Extensible: Support for custom indicators, metrics, and events
- Validated: Full Pydantic v2 validation
Documentation
Full documentation: https://obichan117.github.io/utss
License
MIT
Metadata
Release files for utss 1.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| utss-1.1.0.tar.gz | 15.5 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| utss-1.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 33.1 kB
Release files / utss-1.1.0.tar.gz
| Download URL | utss-1.1.0.tar.gz |
|---|---|
| Size | 15.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
cf528d73884a619bc15f18c94cd0da31151302116fbef37e889ad44398a57bd4
|
|
BLAKE2b-256 checksum How to use checksums |
ef9966850e6bf0559c83e09ca447cbcc90245c0c5a6b60715d6c760c1b70a1b5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.0
|
Release files / utss-1.1.0-py3-none-any.whl
| Download URL | utss-1.1.0-py3-none-any.whl |
|---|---|
| Size | 17.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
39663a0d92fc87bb5e49ab1553a632a8ce2100568f9e77eb37955a76a452d379
|
|
BLAKE2b-256 checksum How to use checksums |
1f75067d837bdf1dbf7f704a09893c7cf4cfd8787eccb1e2193508035e8e23ce
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.0
|
Security for utss 1.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.