Spaces:
Runtime error
Runtime error
Update qlib/mcp_output/start_mcp.py
Browse files
qlib/mcp_output/start_mcp.py
CHANGED
|
@@ -18,6 +18,14 @@ os.system("ls -lh /app/qlib_data/calendars || echo 'No data found'")
|
|
| 18 |
os.system("echo '=== List /app/qlib_data/features (first 10 files) ==='")
|
| 19 |
os.system("ls -lh /app/qlib_data/features | head -n 10 || echo 'No data found'")
|
| 20 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 21 |
project_root = os.path.dirname(os.path.abspath(__file__))
|
| 22 |
mcp_plugin_dir = os.path.join(project_root, "mcp_plugin")
|
| 23 |
if mcp_plugin_dir not in sys.path:
|
|
|
|
| 18 |
os.system("echo '=== List /app/qlib_data/features (first 10 files) ==='")
|
| 19 |
os.system("ls -lh /app/qlib_data/features | head -n 10 || echo 'No data found'")
|
| 20 |
|
| 21 |
+
from qlib.data import D
|
| 22 |
+
|
| 23 |
+
# 打印 day 频率标的
|
| 24 |
+
instruments = D.list_instruments(freq="day", market="cn")
|
| 25 |
+
print("=== Day-frequency instruments ===")
|
| 26 |
+
print(f"Total instruments: {len(instruments)}")
|
| 27 |
+
print("Sample instruments:", instruments[:10])
|
| 28 |
+
|
| 29 |
project_root = os.path.dirname(os.path.abspath(__file__))
|
| 30 |
mcp_plugin_dir = os.path.join(project_root, "mcp_plugin")
|
| 31 |
if mcp_plugin_dir not in sys.path:
|