cufolio

Optimize stock portfolios with GPU-accelerated Mean-CVaR and Mean-Variance workflows.

468|101|Updated Oct 27, 2025
One-click install
npx skills add https://github.com/NVIDIA-AI-Blueprints/cuFOLIO --skill cufolio
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cufolio
Source: https://github.com/NVIDIA-AI-Blueprints/cuFOLIO/tree/main/skills/cufolio
Command: npx skills add https://github.com/NVIDIA-AI-Blueprints/cuFOLIO --skill cufolio

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires cufolio, cvxpy, numpy, pandas, numpy, and includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

The cufolio skill solves the problem of efficiently building, optimizing, backtesting, rebalancing, or analyzing stock portfolios using GPU-accelerated Mean-CVaR and Mean-Variance optimization.

Core Features & Use Cases

  • GPU-accelerated Mean-CVaR: Compute returns, generate KDE scenarios for CVaR, and solve complex optimization problems with cuOpt GPU solver.
  • Mean-Variance Optimization: Solve variance-cap Markowitz allocations as SOCP/QCQP problems with the cuOpt GPU solver.
  • Efficient Frontier: Plot or inspect an efficient frontier for a portfolio universe.
  • Backtesting & Rebalancing: Rigorously test the trading strategies and provide insights into strategy fine-tuning, including backtesting against benchmarks and rebalancing workflows.
  • Use Case: Imagine you need to optimize a stock portfolio with a specific risk aversion level and CVaR constraint. Use cufolio to compute returns, generate scenarios for CVaR, and solve the optimization problem with cuOpt.

Quick Start

Use the cufolio skill to build and backtest an optimized portfolio based on the S&P 500 dataset with a risk aversion level of 1.0 and a confidence level of 0.95.

Frequently Asked Questions about cufolio

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I perform GPU-accelerated Mean-Variance optimization for a stock portfolio?

Mean-Variance optimization for a stock portfolio is accelerated by solving variance-cap Markowitz allocations as SOCP/QCQP problems using the cuOpt GPU solver. You can compute returns and plot the efficient frontier for your portfolio universe.

What is Mean-CVaR optimization and how does GPU acceleration handle it?

Mean-CVaR optimization minimizes Conditional Value at Risk for portfolio allocation. It is handled by generating KDE scenarios for CVaR from returns data and solving the complex optimization problem with the cuOpt GPU solver.

Do I need NVIDIA cuOpt and Python to run quantitative portfolio optimization workflows?

Yes, you need Python, NVIDIA cuOpt, and cuML to run these quantitative portfolio optimization workflows. The environment uses the cufolio package alongside cvxpy, numpy, and pandas for data processing and scenario generation.

Can I backtest trading strategies and rebalance portfolios against benchmarks?

Yes, you can backtest trading strategies and rebalance portfolios against benchmarks. The workflow provides insights into strategy fine-tuning and includes rigorous backtesting against benchmarks and rebalancing workflows.

What's the best way to generate scenarios for CVaR constraints in portfolio optimization?

The best way to generate scenarios for CVaR constraints is by computing stock returns and using Kernel Density Estimation to generate KDE scenarios. These scenarios are then fed into the cuOpt GPU solver to solve the optimization problem.

How do I plot an efficient frontier for a portfolio universe?

You plot an efficient frontier for a portfolio universe by computing expected returns and solving Mean-Variance or Mean-CVaR optimization problems across varying risk aversion levels. The workflow supports plotting and inspecting the frontier directly.