TechKit
TechKit is a high-performance technical analysis library for Python, featuring:
- 🚀 153 Technical Indicators - Complete coverage of all TA-Lib indicators
- ⚡ Blazing Fast - C++ core with O(1) incremental updates
- 🔄 100% TA-Lib Compatible - Drop-in replacement API
- 📊 61 Candlestick Patterns - Full CDL pattern recognition
- 🧵 Thread-Safe - Zero global state, parallel-ready
- 📦 Zero Dependencies - Only NumPy required
Installation
pip install techkit
Platform Support
| Platform | Python | Architecture |
|---|---|---|
| Linux | 3.10-3.13 | x86_64 |
| macOS | 3.10-3.13 | x86_64, arm64 |
| Windows | 3.10-3.13 | AMD64 |
Quick Start
Basic Usage
import numpy as np
from techkit import SMA, RSI, MACD, BBANDS
# Sample price data
prices = np.random.randn(100).cumsum() + 100
# Create indicators
sma = SMA(period=20)
rsi = RSI(period=14)
macd = MACD(fast=12, slow=26, signal=9)
# Calculate (batch)
sma_values = sma.calculate(prices)
rsi_values = rsi.calculate(prices)
macd_result = macd.calculate(prices)
print(f"SMA: {sma_values[-1]:.2f}")
print(f"RSI: {rsi_values[-1]:.2f}")
print(f"MACD: {macd_result.macd[-1]:.4f}")
Streaming / Incremental Updates
from techkit import SMA, RSI
sma = SMA(20)
rsi = RSI(14)
# Process bar by bar (O(1) per update)
for price in live_price_stream():
sma_result = sma.update(price)
rsi_result = rsi.update(price)
if sma_result.valid and rsi_result.valid:
print(f"SMA: {sma_result.value:.2f}, RSI: {rsi_result.value:.2f}")
TA-Lib Drop-in Replacement
# Before (TA-Lib)
import talib
sma = talib.SMA(prices, timeperiod=20)
rsi = talib.RSI(prices, timeperiod=14)
macd, signal, hist = talib.MACD(prices)
# After (TechKit) - Same API!
from techkit import talib_compat as ta
sma = ta.SMA(prices, timeperiod=20)
rsi = ta.RSI(prices, timeperiod=14)
macd, signal, hist = ta.MACD(prices)
Candlestick Patterns
from techkit import CDL_HAMMER, CDL_ENGULFING, CDL_MORNINGSTAR
# Detect patterns
hammer = CDL_HAMMER()
signals = hammer.calculate(open, high, low, close)
# Signals: +100 (bullish), -100 (bearish), 0 (none)
bullish_hammers = np.where(signals > 0)[0]
Indicator Chaining
from techkit import Chain, RSI, EMA, SMA
# Smoothed RSI: RSI(14) → EMA(9)
smoothed_rsi = Chain([RSI(14), EMA(9)])
result = smoothed_rsi.calculate(prices)
# Double smoothed: SMA(10) → SMA(5)
double_smooth = Chain([SMA(10), SMA(5)])
result = double_smooth.calculate(prices)
Pandas Integration
import pandas as pd
from techkit import talib_compat as ta
df = pd.read_csv('ohlcv.csv')
# Directly use DataFrame columns
df['SMA_20'] = ta.SMA(df['close'], timeperiod=20)
df['RSI_14'] = ta.RSI(df['close'], timeperiod=14)
df['ATR_14'] = ta.ATR(df['high'], df['low'], df['close'], timeperiod=14)
macd, signal, hist = ta.MACD(df['close'])
df['MACD'] = macd
df['MACD_Signal'] = signal
df['MACD_Hist'] = hist
📖 Documentation
Full Documentation: https://techkit-docs.netlify.app/
Quick Links
| Topic | Link |
|---|---|
| Installation | Getting Started |
| Quick Start | Quick Start Guide |
| Python API | Python API Reference |
| All Indicators | Indicator List |
| Examples | Code Examples |
| Changelog | Version History |
| 中文文档 | Chinese Documentation |
API Documentation
Indicator Categories
Moving Averages (9)
SMA, EMA, WMA, DEMA, TEMA, KAMA, TRIMA, T3, MA
Momentum Indicators (26)
RSI, MACD, STOCH, STOCHF, STOCHRSI, CCI, ADX, ADXR, MOM, ROC, ROCP, ROCR, ROCR100, WILLR, MFI, ULTOSC, TRIX, APO, PPO, CMO, DX, PLUS_DI, MINUS_DI, PLUS_DM, MINUS_DM, AROON, AROONOSC, BOP
Volatility (4)
ATR, NATR, BBANDS, TRANGE
Volume (4)
OBV, AD, ADOSC, MFI
Statistics (9)
STDDEV, VAR, LINEARREG, LINEARREG_SLOPE, LINEARREG_INTERCEPT, LINEARREG_ANGLE, TSF, BETA, CORREL
Price Transform (4)
AVGPRICE, MEDPRICE, TYPPRICE, WCLPRICE
Math (6)
MAX, MIN, SUM, MIDPOINT, MIDPRICE, MINMAX
Cycle / Hilbert Transform (6)
HT_DCPERIOD, HT_DCPHASE, HT_TRENDMODE, HT_TRENDLINE, HT_PHASOR, HT_SINE
Parabolic SAR (2)
SAR, SAREXT
Candlestick Patterns (61)
CDL_DOJI, CDL_HAMMER, CDL_ENGULFING, CDL_MORNINGSTAR, CDL_EVENINGSTAR, CDL_3WHITESOLDIERS, CDL_3BLACKCROWS, CDL_HARAMI, CDL_PIERCING, CDL_DARKCLOUDCOVER, and 51 more...
Advanced Analytics (17)
Risk Metrics: SharpeRatio, SortinoRatio, CalmarRatio, MaxDrawdown, HistoricalVaR, CVaR
Volatility Models: EWMAVolatility, RealizedVolatility, ParkinsonVolatility, GARCHVolatility
Structure Analysis: ZigZag, SwingHighLow, PivotPoints
Pattern Recognition: HarmonicPattern, ChartPattern
Performance
TechKit uses C++ with O(1) incremental computation:
| Operation | TechKit | TA-Lib |
|---|---|---|
| Single update | O(1) | O(n) |
| Batch (1000 bars) | ~0.1ms | ~0.2ms |
| Memory per indicator | O(period) | O(n) |
Benchmark Example
import time
import numpy as np
from techkit import SMA
prices = np.random.randn(1_000_000).cumsum() + 100
# Batch mode
start = time.time()
result = SMA(20).calculate(prices)
print(f"Batch (1M points): {time.time() - start:.3f}s")
# Streaming mode
sma = SMA(20)
start = time.time()
for price in prices[:100_000]:
sma.update(price)
print(f"Streaming (100K points): {time.time() - start:.3f}s")
Version Information
import techkit
print(techkit.__version__) # "1.2.1"
print(techkit.version()) # "1.2.1"
print(techkit.version_tuple()) # (1, 2, 1)
License
MIT License - see LICENSE for details.
Links
- 📖 Full Documentation - API Reference & Guides
- GitHub Repository
- Issue Tracker
- Changelog
Metadata
Release files for techkit 1.2.9
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 |
|---|---|---|---|---|
| techkit-1.2.9.tar.gz | 50.8 kB | Without provenance | Details for techkit-1.2.9.tar.gz |
Built distributions (wheels)
Total release size: 4.2 MB
Release files / techkit-1.2.9.tar.gz
| Download URL | techkit-1.2.9.tar.gz |
|---|---|
| Size | 50.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ee706aeb1394929e2446fc2bdf85f79c9d36360a2422167888ed84a8a4386d98
|
|
BLAKE2b-256 checksum How to use checksums |
e81e3621bb55a87b5f63026e0263735e117b875f30d53871c958899c3a3bedd8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / techkit-1.2.9-cp312-cp312-win_amd64.whl
| Download URL | techkit-1.2.9-cp312-cp312-win_amd64.whl |
|---|---|
| Size | 305.5 kB |
| Tags | CPython 3.12 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
fe307dd29efa95831a2f1ff686c1f019bb5c46b3e61d0b69781bb1ef9f8db915
|
|
BLAKE2b-256 checksum How to use checksums |
12a809161f8f5db8e8b8ab0cfe3fb17289acefc51d1d6828dadc8730563f75de
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / techkit-1.2.9-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | techkit-1.2.9-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 447.6 kB |
| Tags | CPython 3.12 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
b88fae2838653382082bef6e28957d9a0e0b38b756985e905b32c11a163ffe5d
|
|
BLAKE2b-256 checksum How to use checksums |
cd9b80b16c4d7f494b97743ec4a92806409fce88a307a03620094a84963051f1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / techkit-1.2.9-cp312-cp312-macosx_11_0_arm64.whl
| Download URL | techkit-1.2.9-cp312-cp312-macosx_11_0_arm64.whl |
|---|---|
| Size | 305.0 kB |
| Tags | CPython 3.12 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
a7128e1053fccf79e9cf1bec98b1920e5b1ebf92435510728c09d399fb54374e
|
|
BLAKE2b-256 checksum How to use checksums |
cdcb5b22ee02778d003893bc1f8d506b94afa5cc9034dd2b5b4f40902e51f487
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / techkit-1.2.9-cp312-cp312-macosx_10_14_x86_64.whl
| Download URL | techkit-1.2.9-cp312-cp312-macosx_10_14_x86_64.whl |
|---|---|
| Size | 343.9 kB |
| Tags | CPython 3.12 macOS 10.14+ x86-64 |
|
SHA-256 checksum How to use checksums |
ec3babc5894c4fac465a9b50d4b08c9b0c0a8dce5787906f549bbd39eb735dd0
|
|
BLAKE2b-256 checksum How to use checksums |
c6e3a9fb6ed730efebf088f0f2d3e825449962edc6b3dd74164cb8f4027afb3f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / techkit-1.2.9-cp311-cp311-win_amd64.whl
| Download URL | techkit-1.2.9-cp311-cp311-win_amd64.whl |
|---|---|
| Size | 302.5 kB |
| Tags | CPython 3.11 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
b6f516a7a25f6f91f535b01675bddc98fb813f97252ed6fb51b20bf294eda261
|
|
BLAKE2b-256 checksum How to use checksums |
2b1e07d7730cf63be4edf9ac668f3f7d30dabf907153d3ac459240e240a8bb25
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / techkit-1.2.9-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | techkit-1.2.9-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 448.2 kB |
| Tags | CPython 3.11 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
b9f5b8519a4329066eb2076c1688cdec17190753de29558f2a9cd56002a28b22
|
|
BLAKE2b-256 checksum How to use checksums |
8123a40af73193362f589749e47eb908ef7333f410b5efd5276853be0f94c474
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / techkit-1.2.9-cp311-cp311-macosx_11_0_arm64.whl
| Download URL | techkit-1.2.9-cp311-cp311-macosx_11_0_arm64.whl |
|---|---|
| Size | 304.3 kB |
| Tags | CPython 3.11 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
592d07c84fe57670c4b6a223a4bd98af7735f21bf97297a881f5624200a26341
|
|
BLAKE2b-256 checksum How to use checksums |
2808703de5b215e21ffa883a08d5bbd5fab81b0aacab86892862b2f1b6565384
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / techkit-1.2.9-cp311-cp311-macosx_10_14_x86_64.whl
| Download URL | techkit-1.2.9-cp311-cp311-macosx_10_14_x86_64.whl |
|---|---|
| Size | 337.9 kB |
| Tags | CPython 3.11 macOS 10.14+ x86-64 |
|
SHA-256 checksum How to use checksums |
fb3368eaea6fa5031234f244f618be7bdb7105e192d100d65a89bc473dcc499d
|
|
BLAKE2b-256 checksum How to use checksums |
110c9db0e6f53b0d14de2eb55381be7baf47eea0734cc48c0338f94e996f8ebe
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / techkit-1.2.9-cp310-cp310-win_amd64.whl
| Download URL | techkit-1.2.9-cp310-cp310-win_amd64.whl |
|---|---|
| Size | 302.5 kB |
| Tags | CPython 3.10 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
edba7ba2ed3d5989d93f290534c853683c4a5d0114ec86e8d4fb2ea349dd3186
|
|
BLAKE2b-256 checksum How to use checksums |
fa5c6b89ff91142e73f9b90387e25a928fce0992917f545c7891488ffebdf054
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / techkit-1.2.9-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
| Download URL | techkit-1.2.9-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl |
|---|---|
| Size | 446.5 kB |
| Tags | CPython 3.10 Linux glibc 2.17+ x86-64 |
|
SHA-256 checksum How to use checksums |
d4df2c5b6ba674883e83c654d3fce388496a19e076168ae2718d22fcb7707aa6
|
|
BLAKE2b-256 checksum How to use checksums |
66e0972ed438022bd6552fae9d6f6d75f2372b0f844a2ea06414e2f7adc93e3b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / techkit-1.2.9-cp310-cp310-macosx_11_0_arm64.whl
| Download URL | techkit-1.2.9-cp310-cp310-macosx_11_0_arm64.whl |
|---|---|
| Size | 303.0 kB |
| Tags | CPython 3.10 macOS 11.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
df6f375cada3f9b94159e502682bcaa1339e59c48be13c521546b1acefdcc027
|
|
BLAKE2b-256 checksum How to use checksums |
48d03aa7b79b52fccf4ee090705556ea19ec1328e14d47cafee3217cbe983ba5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Release files / techkit-1.2.9-cp310-cp310-macosx_10_14_x86_64.whl
| Download URL | techkit-1.2.9-cp310-cp310-macosx_10_14_x86_64.whl |
|---|---|
| Size | 336.5 kB |
| Tags | CPython 3.10 macOS 10.14+ x86-64 |
|
SHA-256 checksum How to use checksums |
7e8c663992dd2181a068c949097a58744f2f54b8e952fd181430ff4e6535eb37
|
|
BLAKE2b-256 checksum How to use checksums |
201e2f42ce3be8c5a2da1963b7e61fa7829622c22abbe27956c5ddb67c80fbff
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Security for techkit 1.2.9
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.