quanttide
量潮基础工具箱的 Python SDK。
安装
pip install quanttide
快速开始
from quanttide import LocalStorage
store = LocalStorage("my-app")
data_dir = store.data_dir
# Linux: ~/.local/share/quanttide/my-app/
# macOS: ~/Library/Application Support/quanttide/my-app/
# Windows: %APPDATA%/quanttide/my-app/
标准字段与 Pydantic 模型搭配使用:
from pydantic import BaseModel
from quanttide import IdField, NameField, TitleField
class Project(BaseModel):
id: IdField
name: NameField
title: TitleField | None = None
API
LocalStorage
| 属性 | 返回值 | 说明 |
|---|---|---|
config_dir |
Path |
配置目录 |
data_dir |
Path |
数据目录 |
state_dir |
Path |
状态目录 |
cache_dir |
Path |
缓存目录 |
log_dir |
Path |
日志目录 |
runtime_dir |
Path |
运行时目录 |
标准字段
| 字段类 | Python 类型 | 说明 |
|---|---|---|
IdField |
UUID |
全局唯一主键 |
NameField |
str(≤100) |
唯一标识名 |
OrderField |
int(≥1) |
排序序号 |
LabelField |
str(≤50) |
显示标签 |
TitleField |
str(≤255) |
完整标题 |
DescriptionField |
str |
描述 |
CreatedAtField |
datetime |
创建时间 |
UpdatedAtField |
datetime |
最后更新时间 |
开发
uv sync --dev
uv run pytest --cov=src/ # 含 doctest
uv run ruff check src/ tests/
相关文档
Metadata
Release files for quanttide 0.2.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 | Actions |
|---|---|---|---|---|
| quanttide-0.2.0.tar.gz | 37.2 kB | Without provenance | Details for quanttide-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| quanttide-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for quanttide-0.2.0-py3-none-any.whl |
Total release size: 43.4 kB
Release files / quanttide-0.2.0.tar.gz
| Download URL | quanttide-0.2.0.tar.gz |
|---|---|
| Size | 37.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7acf01144b5524d334695210feccc6ec962d0d9608d38798ef663eb1749c20d9
|
|
BLAKE2b-256 checksum How to use checksums |
91ea26d70a404c59437d5527412142654b8d6c4bf75ce51007c514360bd051ce
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / quanttide-0.2.0-py3-none-any.whl
| Download URL | quanttide-0.2.0-py3-none-any.whl |
|---|---|
| Size | 6.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
658211a22955cfb16573eed3d04d75c767bf5966ce7fd50707bbac3940ae2772
|
|
BLAKE2b-256 checksum How to use checksums |
88aab894b7a59bb0dbcb0d3d02127b170e57e2d6904109db7a95be894f098463
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Security for quanttide 0.2.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.