This is a Python library for technical analysis of financial markets based on 'Chan Theory' (įž čŪš). It computes complex structural elements such as fractals, strokes (bi), line segments, trading ranges (zhongshu), and buy/sell points from candlestick data. The library supports multiple data sources (BaoStock, Akshare, CSV, CCXT), multi-level analysis, customizable algorithms, and plotting via Matplotlib. The code is well-structured with clear separation of concerns, extensive use of caching for performance, and a flexible configuration system. It includes a GUI scanner application for A-shares and demo strategies. The library is designed for both research and production use, with incremental calculation capabilities for real-time updates. While the open-source version omits trading engine and ML features described in the full version, the core analytical engine is robust and reusable.
Ghostfolio is an open-source wealth management application that enables individuals to track and analyze their personal investment portfolios. It supports multiple asset classes (stocks, ETFs, cryptocurrencies, bonds, real estate) and integrates with numerous financial data providers (Yahoo Finance, CoinGecko, Alpha Vantage, etc.) to automatically fetch market prices, historical data, and asset profiles. The system provides comprehensive portfolio performance calculations (ROAI, TWR, MWR), benchmark comparisons, dividend tracking, and a rule-based X-ray analysis for risk assessment (currency/asset class/regional cluster risk, emergency fund coverage, fee ratios). It also includes a FIRE calculator, watchlist, and import/export functionality for activities. The architecture follows a full-stack monorepo pattern using Nx, with an Angular 22 frontend (standalone components, Material Design, Chart.js) and a NestJS 11 backend (Prisma ORM with PostgreSQL, Redis caching, Bull queues for background data gathering). Authentication supports JWT, OAuth (Google, OIDC), API keys, and WebAuthn passkeys. The system is self-hostable via Docker Compose and includes a premium subscription tier managed through Stripe. The codebase is modular with shared libraries (`libs/common` for DTOs, interfaces, utilities; `libs/ui` for reusable Angular components) and a clear separation of concerns across API modules, services, and queue processors. Key highlights include a pluggable data provider abstraction, an abstract portfolio calculator with caching and retry logic, a comprehensive permission and scope system for fine-grained access control, and a rich UI component library with Storybook documentation. The project is actively maintained with frequent releases, extensive Prisma migrations, and a large test suite for portfolio calculations and import validation. While the codebase shows some technical drift (proliferation of environment variables, deprecated endpoints, and multiple data provider integrations), the overall engineering quality is strong, with well-structured modules and reusable patterns that could be extracted for other financial applications.
This repository implements an agentic crypto trading platform called AI Market Maker (AIMM). Despite the name, the code is not a low-latency market-making engine; it is a multi-agent hedge-fund-style trading stack that combines LLM-driven research agents with deterministic quant logic for backtesting, paper trading, and live trading. The core execution path is a LangGraph workflow: nine Tier-0 specialist agents (monetary, news, TA, on-chain, order flow, etc.) produce structured signals, a weighted arbitrator fuses them into trade intents, a Risk Guard vetoes dangerous proposals, and portfolio management routes execution through an OMS with an in-memory or SQLite ledger. The platform includes a FastAPI backend with REST and streaming endpoints, a Next.js/React dashboard, Docker deployment, Alembic migrations, CI, and a large test suite.
This repository is a Python client library for the Alpha Vantage financial data API. It provides synchronous and asynchronous wrappers for accessing stock/cryptocurrency time series, technical indicators, foreign exchange rates, commodities, economic indicators, fundamental data, options, and news sentiment. The library is designed as a straightforward SDK with a decorator-based architecture that handles API key injection, URL construction, and output formatting (JSON, pandas DataFrame, CSV). The codebase includes a comprehensive test suite with mock data and integration tests. However, it exhibits technical drift: declared support for Python 2.7 (EOL), an outdated CI configuration (Travis on Ubuntu Xenial), a hardcoded version number in documentation that differs from the library version, and duplication of core logic between synchronous and async modules. The library is functional and widely used, but not exemplary in terms of modern Python practices or maintainability.
This repository is a Chinese futures algorithmic trading system centered on the CTP (Commodity Trading Platform) native protocol. It comprises a C++ pybind11 bridge for low-latency market data and order execution, Python trading strategies (e.g., channel breakout, experimental transformer-based models), and a Django web dashboard for monitoring positions, orders, signals, performance, and correlations. The architecture is hybrid: the native module handles real-time CTP communication, while Python strategies run on an in-process event bus with Redis-like pub/sub. The dashboard visualizes trading metrics with ECharts and provides admin CRUD via Django admin. The system is production-oriented but exhibits several maintenance concerns: hardcoded secrets, outdated frontend libraries (Bootstrap 3, jQuery 3.1), duplicate config loading, and an incomplete ML integration. Despite these, the core CTP bridge and strategy framework are well-constructed and demonstrate solid engineering for the niche domain of Chinese futures trading.