gradient-methods

Implement gradient descent, accelerated methods, and Newton's method for optimization.

3.9k|296|Updated Dec 23, 2025
One-click install
npx skills add https://github.com/parcadei/Continuous-Claude-v3 --skill gradient-methods-parcadei
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: gradient-methods
Source: https://github.com/parcadei/Continuous-Claude-v3/tree/main/.claude/skills/math/optimization/gradient-methods
Command: npx skills add https://github.com/parcadei/Continuous-Claude-v3 --skill gradient-methods-parcadei

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires scipy, sympy, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill provides strategies and tools for solving optimization problems using gradient-based methods, helping users find optimal solutions efficiently.

Core Features & Use Cases

  • Gradient Descent Variants: Implements basic and accelerated gradient descent methods.
  • Step Size Selection: Offers guidance on choosing appropriate step sizes (fixed, backtracking, adaptive).
  • Newton's Method: Includes information on Newton's method and its quasi-Newton approximations.
  • Use Case: When facing a complex function minimization task, this skill can guide you through selecting the right algorithm and parameters for faster convergence.

Quick Start

Use the gradient-methods skill to find the minimum of the function x^2 + y^2 using the CG method.

Frequently Asked Questions about gradient-methods

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

FAQPage Schema
How do I choose the right step size for gradient descent in Python?

Choosing an appropriate step size for gradient descent is critical for convergence. This skill provides guidance on fixed, backtracking, and adaptive step size selection techniques to help ensure your optimization algorithm reaches a minimum efficiently.

What is the difference between momentum and Nesterov accelerated gradient methods?

Momentum and Nesterov accelerated methods are both advanced gradient descent variants designed to speed up convergence. This skill covers their distinct problem-solving strategies and tool commands to help you apply the correct accelerated optimization method.

Does scipy support Newton's method with Hessian approximations?

Yes, scipy supports Newton's method and quasi-Newton approximations for optimization. This skill includes information on utilizing these methods alongside tool commands to improve convergence when minimizing complex functions.

How do I diagnose convergence issues when using gradient descent?

Diagnosing convergence issues in gradient descent requires analyzing the optimization trajectory. This skill includes specific diagnostics for convergence problems and references nonlinear programming concepts to help troubleshoot poor performance.

Can I use sympy to find the minimum of a function using the CG method?

You can use sympy for symbolic calculations to define your function and apply the CG method to find its minimum. This skill demonstrates how to optimize functions like x^2 + y^2 using conjugate gradient techniques.