[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6NVKZ95GZCZ9GK6BR1VVGRH":3,"skill-same:01M6NVKZ95GZCZ9GK6BR1VVGRH":58},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":29,"linkOnly":30,"markdownContent":31,"markdownBody":32,"frontMatter":33,"refName":36,"commitSha":37,"skillDirectory":38,"forksCount":14,"repositoryHtmlUrl":39,"repositoryHomepageUrl":6,"ownerHtmlUrl":40,"ownerBlogUrl":41,"ownerDescription":42,"updatedAt":43,"install":44,"resources":57},"01M6NVKZ95GZCZ9GK6BR1VVGRH","gradient-methods",null,"Problem-solving strategies for gradient methods in optimization","rubicanjr\u002FFinCognis","rubicanjr","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F234912519?v=4","01M6NT156NND8J474G34SB3923","Rubi","01M6NT15B70RWXE1N3YV0BZY8A",0,"MIT","https:\u002F\u002Fgithub.com\u002Frubicanjr\u002FFinCognis\u002Fblob\u002Fmain\u002Fskills\u002Fmath\u002Foptimization\u002Fgradient-methods\u002FSKILL.md",[],[19,20,21,22,23,24,25,26,27,28],"methods","gradient","gradient methods","Optimization","Bash","read","problem-solving","strategies","problem","for","2026-11-10 10:12:30",false,"---\nname: gradient-methods\ndescription: \"Problem-solving strategies for gradient methods in optimization\"\nallowed-tools: [Bash, Read]\n---\n\n# Gradient Methods\n\n## When to Use\n\nUse this skill when working on gradient-methods problems in optimization.\n\n## Decision Tree\n\n\n1. **Basic Gradient Descent**\n   - Update: x_{k+1} = x_k - alpha * grad f(x_k)\n   - Step size alpha: fixed, diminishing, or line search\n   - Convergence: O(1\u002Fk) for convex, linear for strongly convex\n\n2. **Step Size Selection**\n   | Method | Approach |\n   |--------|----------|\n   | Fixed | alpha constant (requires tuning) |\n   | Backtracking | Armijo condition: f(x - alpha*grad) \u003C= f(x) - c*alpha*||grad||^2 |\n   | Exact line search | minimize f(x - alpha*grad) over alpha |\n   | Adaptive | Adam, RMSprop (ML applications) |\n\n3. **Accelerated Methods**\n   - Momentum: add velocity term\n   - Nesterov: look-ahead gradient\n   - Conjugate gradient: for quadratic functions\n   - `scipy.optimize.minimize(f, x0, method='CG')` - conjugate gradient\n\n4. **Newton's Method**\n   - Update: x_{k+1} = x_k - H^{-1} * grad f\n   - Requires Hessian (expensive but quadratic convergence)\n   - Quasi-Newton (BFGS): approximate Hessian\n   - `scipy.optimize.minimize(f, x0, method='BFGS')`\n\n5. **Convergence Diagnostics**\n   - Monitor ||grad f|| \u003C tolerance\n   - Check function value decrease\n   - Watch for oscillation (step size too large)\n   - `sympy_compute.py diff \"f\" --var x` for gradient\n\n\n## Tool Commands\n\n### Scipy_Bfgs\n```bash\nuv run python -c \"from scipy.optimize import minimize; res = minimize(lambda x: (x[0]-1)**2 + 100*(x[1]-x[0]**2)**2, [0, 0], method='BFGS'); print('Rosenbrock min at', res.x)\"\n```\n\n### Scipy_Cg\n```bash\nuv run python -c \"from scipy.optimize import minimize; res = minimize(lambda x: x[0]**2 + x[1]**2, [1, 1], method='CG'); print('Min at', res.x)\"\n```\n\n### Sympy_Gradient\n```bash\nuv run python -m runtime.harness scripts\u002Fsympy_compute.py diff \"x**2 + y**2\" --var \"[x, y]\"\n```\n\n## Key Techniques\n\n*From indexed textbooks:*\n\n- [nonlinear programming_tif] Gradient Methods** - These methods use gradient information to iteratively approach the optimum. Convergence** - Addressing convergence properties. Descent Directions and Stepsize Rules:** Focuses on how to choose descent directions and appropriate step sizes.\n- [nonlinear programming_tif] The application of gradient methods to unconstrained optimal control prob- lems is straightforward in principle. For example the steepest descent method takes the form W = b oMV H, (kb ph,y), i=0,. Pl = Thus, given u¥, one computes zF by forward propagation of the system equation, and then p*¥ by backward propagation of the adjoint equation.\n- [nonlinear programming_tif] Footer or Trailing Row**: - There is an empty concluding element indicated by a single \". Overall, this table serves as an index for chapters or sections within a document, with particular emphasis on optimization methods and related mathematical strategies, as evidenced by the listed methods like Gradient, Newton, and other derivative techniques. The scattered letters and empty slots may denote a form of stylistic or formatting choice rather than meaningful content in this context.\n- [nonlinear programming_tif] Zoutendijk’s method uses tw ) oscalatse)Oand'ye 0,1), a i ! P, where ¢ — Y™k € and my is the firs onnegative k ok 28 %, ) it T #(z*,7\"e) \u003C -y (a) Show that (b) Prove that {d*} is gradient relat ishi i i Tt pones A related, thus establishing stationarity of the 2. Min-H Method for Optimal Control) Consider the problem of findin g sequences u = (z1,22,.\n- [nonlinear programming_tif] Mustration of the function f of Exercise 1. Stability) (www) We are often interested in whether optimal solutions change radically when the problem data are slightly perturbed. This issue is addressed by stability analysis, to be contrasted with sensitivity analysis, which deals with how much optimal solutions change when problem data change.\n\n## Cognitive Tools Reference\n\nSee `.claude\u002Fskills\u002Fmath-mode\u002FSKILL.md` for full tool documentation.\n","# Gradient Methods\n\n## When to Use\n\nUse this skill when working on gradient-methods problems in optimization.\n\n## Decision Tree\n\n\n1. **Basic Gradient Descent**\n   - Update: x_{k+1} = x_k - alpha * grad f(x_k)\n   - Step size alpha: fixed, diminishing, or line search\n   - Convergence: O(1\u002Fk) for convex, linear for strongly convex\n\n2. **Step Size Selection**\n   | Method | Approach |\n   |--------|----------|\n   | Fixed | alpha constant (requires tuning) |\n   | Backtracking | Armijo condition: f(x - alpha*grad) \u003C= f(x) - c*alpha*||grad||^2 |\n   | Exact line search | minimize f(x - alpha*grad) over alpha |\n   | Adaptive | Adam, RMSprop (ML applications) |\n\n3. **Accelerated Methods**\n   - Momentum: add velocity term\n   - Nesterov: look-ahead gradient\n   - Conjugate gradient: for quadratic functions\n   - `scipy.optimize.minimize(f, x0, method='CG')` - conjugate gradient\n\n4. **Newton's Method**\n   - Update: x_{k+1} = x_k - H^{-1} * grad f\n   - Requires Hessian (expensive but quadratic convergence)\n   - Quasi-Newton (BFGS): approximate Hessian\n   - `scipy.optimize.minimize(f, x0, method='BFGS')`\n\n5. **Convergence Diagnostics**\n   - Monitor ||grad f|| \u003C tolerance\n   - Check function value decrease\n   - Watch for oscillation (step size too large)\n   - `sympy_compute.py diff \"f\" --var x` for gradient\n\n\n## Tool Commands\n\n### Scipy_Bfgs\n```bash\nuv run python -c \"from scipy.optimize import minimize; res = minimize(lambda x: (x[0]-1)**2 + 100*(x[1]-x[0]**2)**2, [0, 0], method='BFGS'); print('Rosenbrock min at', res.x)\"\n```\n\n### Scipy_Cg\n```bash\nuv run python -c \"from scipy.optimize import minimize; res = minimize(lambda x: x[0]**2 + x[1]**2, [1, 1], method='CG'); print('Min at', res.x)\"\n```\n\n### Sympy_Gradient\n```bash\nuv run python -m runtime.harness scripts\u002Fsympy_compute.py diff \"x**2 + y**2\" --var \"[x, y]\"\n```\n\n## Key Techniques\n\n*From indexed textbooks:*\n\n- [nonlinear programming_tif] Gradient Methods** - These methods use gradient information to iteratively approach the optimum. Convergence** - Addressing convergence properties. Descent Directions and Stepsize Rules:** Focuses on how to choose descent directions and appropriate step sizes.\n- [nonlinear programming_tif] The application of gradient methods to unconstrained optimal control prob- lems is straightforward in principle. For example the steepest descent method takes the form W = b oMV H, (kb ph,y), i=0,. Pl = Thus, given u¥, one computes zF by forward propagation of the system equation, and then p*¥ by backward propagation of the adjoint equation.\n- [nonlinear programming_tif] Footer or Trailing Row**: - There is an empty concluding element indicated by a single \". Overall, this table serves as an index for chapters or sections within a document, with particular emphasis on optimization methods and related mathematical strategies, as evidenced by the listed methods like Gradient, Newton, and other derivative techniques. The scattered letters and empty slots may denote a form of stylistic or formatting choice rather than meaningful content in this context.\n- [nonlinear programming_tif] Zoutendijk’s method uses tw ) oscalatse)Oand'ye 0,1), a i ! P, where ¢ — Y™k € and my is the firs onnegative k ok 28 %, ) it T #(z*,7\"e) \u003C -y (a) Show that (b) Prove that {d*} is gradient relat ishi i i Tt pones A related, thus establishing stationarity of the 2. Min-H Method for Optimal Control) Consider the problem of findin g sequences u = (z1,22,.\n- [nonlinear programming_tif] Mustration of the function f of Exercise 1. Stability) (www) We are often interested in whether optimal solutions change radically when the problem data are slightly perturbed. This issue is addressed by stability analysis, to be contrasted with sensitivity analysis, which deals with how much optimal solutions change when problem data change.\n\n## Cognitive Tools Reference\n\nSee `.claude\u002Fskills\u002Fmath-mode\u002FSKILL.md` for full tool documentation.\n",{"name":5,"description":7,"allowed-tools":34},[23,35],"Read","main","70e1c350500ee750987420bbae48837afa906b7e","skills\u002Fmath\u002Foptimization\u002Fgradient-methods","https:\u002F\u002Fgithub.com\u002Frubicanjr\u002FFinCognis","https:\u002F\u002Fgithub.com\u002Frubicanjr","linktr.ee\u002Ffinanskodu","Industrial Engineer & CIO @FinansKodu. Architecting AI-driven financial agents and autonomous workflows. 🏗️ Building systems, not just prompts.","2026-06-09 13:50:15",{"source":8,"skillName":5,"commands":45,"prompt":55,"zipAvailable":56},[46,49,52],{"tool":47,"command":48},"npx","npx skills add rubicanjr\u002FFinCognis --skill gradient-methods",{"tool":50,"command":51},"bunx","bunx skills add rubicanjr\u002FFinCognis --skill gradient-methods",{"tool":53,"command":54},"pnpm","pnpm dlx skills add rubicanjr\u002FFinCognis --skill gradient-methods","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Frubicanjr\u002FFinCognis\u002Fblob\u002Fmain\u002Fskills\u002Fmath\u002Foptimization\u002Fgradient-methods\u002FSKILL.md",true,[],[59,80,89,108,137,156],{"skillNo":60,"name":61,"nameZh":6,"description":62,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":63,"categories":64,"keywords":70,"publishedAt":29},"01M6NWS9DAXJTADT4T5MB49X8W","workflow-router","Goal-based workflow orchestration - routes tasks to specialist agents based on user goals","https:\u002F\u002Fgithub.com\u002Frubicanjr\u002FFinCognis\u002Fblob\u002Fmain\u002Fskills\u002Fworkflow-router\u002FSKILL.md",[65],{"categoryNo":66,"categoryName":67,"taxonomyType":68,"taxonomyTypeDesc":69},"01JBSEEDCAT000000000000023","Skill与智能体开发","SCENARIO","使用场景",[71,72,73,74,75,76,77,78,79],"workflow router","workflow","router","orchestration","goals","goal","user","workflow orchestration","tasks",{"skillNo":81,"name":82,"nameZh":6,"description":83,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":84,"categories":85,"keywords":86,"publishedAt":29},"01M6NWS3RETSC0SHP16HP66E14","wiring","Wiring Verification","https:\u002F\u002Fgithub.com\u002Frubicanjr\u002FFinCognis\u002Fblob\u002Fmain\u002Fskills\u002Fwiring\u002FSKILL.md",[],[82,87,88],"verification","false",{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":98,"publishedAt":29},"01M6NWS0XW9CVQZBDA1EGW0TWC","websocket-patterns","Connection management, room patterns, reconnection strategies, message buffering, and binary protocol design.","https:\u002F\u002Fgithub.com\u002Frubicanjr\u002FFinCognis\u002Fblob\u002Fmain\u002Fskills\u002Fwebsocket-patterns\u002Fskill.md",[95],{"categoryNo":96,"categoryName":97,"taxonomyType":68,"taxonomyTypeDesc":69},"01JBSEEDCAT000000000000015","视觉设计",[99,100,101,102,103,104,105,26,106,107],"websocket","patterns","websocket patterns","design","protocol","management","message","binary","connection",{"skillNo":109,"name":110,"nameZh":6,"description":111,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":112,"categories":113,"keywords":118,"publishedAt":29},"01M6NWRDQDX9ZNETAWRRMQWV52","visual-verdict","Screenshot comparison QA for frontend development. Takes a screenshot of the current implementation, scores it across multiple visual dimensions, and returns a structured PASS\u002FREVISE\u002FFAIL verdict with concrete fixes. Use when implementing UI from a design reference or verifying visual correctness.","https:\u002F\u002Fgithub.com\u002Frubicanjr\u002FFinCognis\u002Fblob\u002Fmain\u002Fskills\u002Fvisual-verdict\u002FSKILL.md",[114,117],{"categoryNo":115,"categoryName":116,"taxonomyType":68,"taxonomyTypeDesc":69},"01JBSEEDCAT000000000000009","前端开发",{"categoryNo":66,"categoryName":67,"taxonomyType":68,"taxonomyTypeDesc":69},[119,120,121,122,123,124,125,126,127,28,128,129,130,102,131,132,133,134,135,136],"visual","verdict","visual verdict","ui","across","revise","comparison","correctness","implementing","fixes","dimensions","frontend","development","qa","screenshot","returns","use","frontend development",{"skillNo":138,"name":139,"nameZh":6,"description":140,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":141,"categories":142,"keywords":143,"publishedAt":29},"01M6NWR8HSNRS7MNDK2J02QYMN","verification-loop","Comprehensive verification system covering build, types, lint, tests, security, and diff review before a PR.","https:\u002F\u002Fgithub.com\u002Frubicanjr\u002FFinCognis\u002Fblob\u002Fmain\u002Fskills\u002Fverification-loop\u002FSKILL.md",[],[144,145,87,146,147,148,149,150,151,152,153,154,155],"verification loop","loop","lint","review","security","pr","system","diff","build","tests","diff review","types",{"skillNo":157,"name":158,"nameZh":6,"description":159,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":160,"categories":161,"keywords":162,"publishedAt":29},"01M6NWR4HHSFR0VR5EXFRWA747","vector-db-patterns","Embedding strategies, ANN algorithms, hybrid search, RAG chunking strategies, and reranking for semantic search and retrieval.","https:\u002F\u002Fgithub.com\u002Frubicanjr\u002FFinCognis\u002Fblob\u002Fmain\u002Fskills\u002Fvector-db-patterns\u002Fskill.md",[],[163,164,165,166,100,167,168,169,170,26,171,172,173,174,175,28,176,177],"vector db patterns","vector db","db","vector","semantic search","search","embedding strategies","algorithms","chunking","semantic","retrieval","embedding","Hybrid Search","hybrid","rag"]