"Vibe-Trading: Your Personal Trading Agent"
Python ai-agentalgorithmic-tradingbacktestingfintechllmmcpmulti-agentpythonquantitative-financetrading
docs(factors): fix the swapped cntp/cntn comments and the "~~" in the notes
cgycoreyba051fc89126
diff --git a/agent/src/factors/zoo/qlib158/cntd10.py b/agent/src/factors/zoo/qlib158/cntd10.pyindex a10053d15..babf2a9d3 100644--- a/agent/src/factors/zoo/qlib158/cntd10.py+++ b/agent/src/factors/zoo/qlib158/cntd10.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 10,'min_warmup_bars': 10,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~30% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~30% missing bars).',}diff --git a/agent/src/factors/zoo/qlib158/cntd20.py b/agent/src/factors/zoo/qlib158/cntd20.pyindex d5effedd3..89e12340d 100644--- a/agent/src/factors/zoo/qlib158/cntd20.py+++ b/agent/src/factors/zoo/qlib158/cntd20.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 20,'min_warmup_bars': 20,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~15% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~15% missing bars).',}diff --git a/agent/src/factors/zoo/qlib158/cntd30.py b/agent/src/factors/zoo/qlib158/cntd30.pyindex 515d4adcb..78d01230a 100644--- a/agent/src/factors/zoo/qlib158/cntd30.py+++ b/agent/src/factors/zoo/qlib158/cntd30.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 30,'min_warmup_bars': 30,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~10% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~10% missing bars).',}diff --git a/agent/src/factors/zoo/qlib158/cntd5.py b/agent/src/factors/zoo/qlib158/cntd5.pyindex c86e6e808..a4de02ed3 100644--- a/agent/src/factors/zoo/qlib158/cntd5.py+++ b/agent/src/factors/zoo/qlib158/cntd5.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 5,'min_warmup_bars': 5,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~40% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~40% missing bars).',}diff --git a/agent/src/factors/zoo/qlib158/cntd60.py b/agent/src/factors/zoo/qlib158/cntd60.pyindex 687cf02d9..b902fb9ce 100644--- a/agent/src/factors/zoo/qlib158/cntd60.py+++ b/agent/src/factors/zoo/qlib158/cntd60.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 60,'min_warmup_bars': 60,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~5% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~5% missing bars).',}diff --git a/agent/src/factors/zoo/qlib158/cntn10.py b/agent/src/factors/zoo/qlib158/cntn10.pyindex d3794432b..4820a8ab3 100644--- a/agent/src/factors/zoo/qlib158/cntn10.py+++ b/agent/src/factors/zoo/qlib158/cntn10.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 10,'min_warmup_bars': 10,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~30% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~30% missing bars).',}@@ -27,5 +27,5 @@ def compute(panel: dict[str, pd.DataFrame]) -> pd.DataFrame:"""Return qlib158 CNTN10 on the supplied OHLCV panel."""c = panel['close']prev = c.shift(1)- dn = (c < prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not an up day+ dn = (c < prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not a down dayreturn dn.rolling(window=10, min_periods=10).mean()diff --git a/agent/src/factors/zoo/qlib158/cntn20.py b/agent/src/factors/zoo/qlib158/cntn20.pyindex c6b04c6c4..94133ad55 100644--- a/agent/src/factors/zoo/qlib158/cntn20.py+++ b/agent/src/factors/zoo/qlib158/cntn20.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 20,'min_warmup_bars': 20,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~15% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~15% missing bars).',}@@ -27,5 +27,5 @@ def compute(panel: dict[str, pd.DataFrame]) -> pd.DataFrame:"""Return qlib158 CNTN20 on the supplied OHLCV panel."""c = panel['close']prev = c.shift(1)- dn = (c < prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not an up day+ dn = (c < prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not a down dayreturn dn.rolling(window=20, min_periods=20).mean()diff --git a/agent/src/factors/zoo/qlib158/cntn30.py b/agent/src/factors/zoo/qlib158/cntn30.pyindex 054bd2bb8..dcc20161f 100644--- a/agent/src/factors/zoo/qlib158/cntn30.py+++ b/agent/src/factors/zoo/qlib158/cntn30.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 30,'min_warmup_bars': 30,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~10% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~10% missing bars).',}@@ -27,5 +27,5 @@ def compute(panel: dict[str, pd.DataFrame]) -> pd.DataFrame:"""Return qlib158 CNTN30 on the supplied OHLCV panel."""c = panel['close']prev = c.shift(1)- dn = (c < prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not an up day+ dn = (c < prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not a down dayreturn dn.rolling(window=30, min_periods=30).mean()diff --git a/agent/src/factors/zoo/qlib158/cntn5.py b/agent/src/factors/zoo/qlib158/cntn5.pyindex 76b96be8a..cd8d490ec 100644--- a/agent/src/factors/zoo/qlib158/cntn5.py+++ b/agent/src/factors/zoo/qlib158/cntn5.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 5,'min_warmup_bars': 5,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~40% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~40% missing bars).',}@@ -27,5 +27,5 @@ def compute(panel: dict[str, pd.DataFrame]) -> pd.DataFrame:"""Return qlib158 CNTN5 on the supplied OHLCV panel."""c = panel['close']prev = c.shift(1)- dn = (c < prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not an up day+ dn = (c < prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not a down dayreturn dn.rolling(window=5, min_periods=5).mean()diff --git a/agent/src/factors/zoo/qlib158/cntn60.py b/agent/src/factors/zoo/qlib158/cntn60.pyindex 61fec2163..c4e574557 100644--- a/agent/src/factors/zoo/qlib158/cntn60.py+++ b/agent/src/factors/zoo/qlib158/cntn60.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 60,'min_warmup_bars': 60,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~5% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~5% missing bars).',}@@ -27,5 +27,5 @@ def compute(panel: dict[str, pd.DataFrame]) -> pd.DataFrame:"""Return qlib158 CNTN60 on the supplied OHLCV panel."""c = panel['close']prev = c.shift(1)- dn = (c < prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not an up day+ dn = (c < prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not a down dayreturn dn.rolling(window=60, min_periods=60).mean()diff --git a/agent/src/factors/zoo/qlib158/cntp10.py b/agent/src/factors/zoo/qlib158/cntp10.pyindex 916473ad8..773d96207 100644--- a/agent/src/factors/zoo/qlib158/cntp10.py+++ b/agent/src/factors/zoo/qlib158/cntp10.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 10,'min_warmup_bars': 10,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~30% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~30% missing bars).',}@@ -27,5 +27,5 @@ def compute(panel: dict[str, pd.DataFrame]) -> pd.DataFrame:"""Return qlib158 CNTP10 on the supplied OHLCV panel."""c = panel['close']prev = c.shift(1)- up = (c > prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not a down day+ up = (c > prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not an up dayreturn up.rolling(window=10, min_periods=10).mean()diff --git a/agent/src/factors/zoo/qlib158/cntp20.py b/agent/src/factors/zoo/qlib158/cntp20.pyindex 07593398b..8b6c325dc 100644--- a/agent/src/factors/zoo/qlib158/cntp20.py+++ b/agent/src/factors/zoo/qlib158/cntp20.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 20,'min_warmup_bars': 20,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~15% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~15% missing bars).',}@@ -27,5 +27,5 @@ def compute(panel: dict[str, pd.DataFrame]) -> pd.DataFrame:"""Return qlib158 CNTP20 on the supplied OHLCV panel."""c = panel['close']prev = c.shift(1)- up = (c > prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not a down day+ up = (c > prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not an up dayreturn up.rolling(window=20, min_periods=20).mean()diff --git a/agent/src/factors/zoo/qlib158/cntp30.py b/agent/src/factors/zoo/qlib158/cntp30.pyindex 72750d57a..5fb9ec88d 100644--- a/agent/src/factors/zoo/qlib158/cntp30.py+++ b/agent/src/factors/zoo/qlib158/cntp30.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 30,'min_warmup_bars': 30,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~10% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~10% missing bars).',}@@ -27,5 +27,5 @@ def compute(panel: dict[str, pd.DataFrame]) -> pd.DataFrame:"""Return qlib158 CNTP30 on the supplied OHLCV panel."""c = panel['close']prev = c.shift(1)- up = (c > prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not a down day+ up = (c > prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not an up dayreturn up.rolling(window=30, min_periods=30).mean()diff --git a/agent/src/factors/zoo/qlib158/cntp5.py b/agent/src/factors/zoo/qlib158/cntp5.pyindex 09a400ec3..3023c89c6 100644--- a/agent/src/factors/zoo/qlib158/cntp5.py+++ b/agent/src/factors/zoo/qlib158/cntp5.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 5,'min_warmup_bars': 5,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~40% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~40% missing bars).',}@@ -27,5 +27,5 @@ def compute(panel: dict[str, pd.DataFrame]) -> pd.DataFrame:"""Return qlib158 CNTP5 on the supplied OHLCV panel."""c = panel['close']prev = c.shift(1)- up = (c > prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not a down day+ up = (c > prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not an up dayreturn up.rolling(window=5, min_periods=5).mean()diff --git a/agent/src/factors/zoo/qlib158/cntp60.py b/agent/src/factors/zoo/qlib158/cntp60.pyindex 6a074c5d4..4927888f0 100644--- a/agent/src/factors/zoo/qlib158/cntp60.py+++ b/agent/src/factors/zoo/qlib158/cntp60.py@@ -19,7 +19,7 @@ __alpha_meta__ = {'frequency': ['1d'],'decay_horizon': 60,'min_warmup_bars': 60,- 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~~5% missing bars).',+ 'notes': 'A missing close leaves window+1 rolling rows NaN; on sparse panels this can trigger the >95% NaN registry guard (from ~5% missing bars).',}@@ -27,5 +27,5 @@ def compute(panel: dict[str, pd.DataFrame]) -> pd.DataFrame:"""Return qlib158 CNTP60 on the supplied OHLCV panel."""c = panel['close']prev = c.shift(1)- up = (c > prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not a down day+ up = (c > prev).astype('float64').where(c.notna() & prev.notna()) # a missing close is not an up dayreturn up.rolling(window=60, min_periods=60).mean()