- Home
- Skills
- Business & Operations
- CVXPY Optimization & Debugging
CVXPY Optimization & Debugging
by oshun
Turn "best choice under limits" questions into CVXPY models, solve and verify them, explain shadow prices, and debug models that fail or look wrong.
$19
CVXPY Optimization & Debugging
Example session with this skill installed
A small workshop makes chairs and tables. A chair earns $30 profit and a table $50. Each chair takes 4 hours of carpentry and 2 hours of finishing; each table takes 6 hours of carpentry and 4 hours of finishing. We have 120 carpentry hours and 70 finishing hours, and can sell at most 15 tables. How many of each should we make, and what is one extra hour of carpentry worth?
- Read your context and instructions
- Compiled the cvxpy optimization
Make 15 chairs and 10 tables for $950 profit. Carpentry and finishing are both fully used; the 15-table limit has 5 to spare. One extra carpentry hour is worth $5 (checked by re-solving with 119 and 121 hours), and that rate holds between 105 and 140 carpentry hours. The solve script is saved so you can change the numbers and re-run it.
Connects securely to your tools. The creator never sees your data.
About this skill
Ask your agent a "best choice under limits" question in plain language — how many of each product to make, how to split a budget, which projects to fund, what an extra hour of machine time is worth — and it builds a CVXPY model, solves it, checks the answer and explains it in your own terms.
Optimization
- Turns everyday questions into linear, quadratic, second-order cone, semidefinite and integer programs, even when you never say "optimize".
- Explains the model in plain words for non-technical users, or in math when you want it.
- Reports which limits bind and what each is worth (shadow prices), and confirms them by re-solving with nudged data.
- Verifies every answer: constraint violations, recomputed objective, closed-form checks, integrality.
- Leaves a re-runnable Python script.
Debugging (bundled as references/debugging.md)
- Pinpoints which part of a model breaks CVXPY's DCP rules, with a table of standard rewrites.
- Finds the conflicting constraints in an infeasible model and says how much each must give, in your units.
- Catches models reported as "unbounded" that are really infeasible.
- Flags silent domain restrictions (e.g.
x**3quietly forcing x ≥ 0) that make CVXPY answer a different problem than the one you meant. - Handles solver errors, inaccurate solutions, DGP and quasiconvex problems.
Every code snippet in the skill is covered by a test suite, and the skill was evaluated on realistic prompts against independently computed reference answers.
Solves convex problems (plus mixed-integer LPs with HIGHS). Nonconvex problems are identified and explained, with a suggested approach, but not solved globally. Mixed-integer QPs need a solver such as SCIP, Gurobi or MOSEK. Very small problems may be answered by direct reasoning rather than a solver run.
How to use
- 1
Connect your agent to the Agensi MCP
Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup
- 2
Sign in to Agensi
Your agent shows a sign-in link. Sign in and click Allow.
- 3
Ask for what you need
Your agent loads this skill and uses it on your task. It always asks before buying a skill.
Reviews
No reviews yet
Be one of the first to try it. Every listed skill goes through the trust checks below.
Security scanned
Checked by our 8-point scan before listing
Fresh listing
Recently published to Agensi
Money-back guarantee
Doesn't do what its page promises? You get your money back.
Trust & safety
Security scan
Security scan passed 16 days ago
- Software
Python 3.10+cvxpy (pip install cvxpy)
Permissions
Allowed Hosts
File Scopes
Runs Python locally to solve the model. No network access needed once cvxpy is installed.
What's inside
Frequently Asked Questions
New in Business & Operations
Find more skills like this on the Claude Skills Marketplace, the Codex Skills Marketplace and the Gemini Skills Marketplace, or browse Claude Skills for Business & Operations.