Hill climbing
Hill climbing is an iterative local-search optimization method that repeatedly moves from a candidate solution to a better neighboring solution.
Self-Improving Agents
An iterative search method that makes local changes to a candidate and retains changes that improve its score.
- How it is used
- Uses measured improvements to select successive prompt or artifact rewrites within an offline improvement loop.
- How deep it goes
- Works through the propose-measure-accept rule and its implementation, then demonstrates why a strict ratchet stalls at local peaks.
- Examples
- Tests ten revenue-policy rewrites against a 0.63 baseline and contrasts a greedy climber with archive search on a toy landscape.
- What you can do after
- Build it from scratch as a strict-improvement loop and recognize when a local peak calls for broader search.
Optimization Algorithms: AI techniques for design, planning, and control problems
A local search algorithm that repeatedly moves from a candidate solution to an improving neighboring solution.
- How it is used
- Uses heuristic-guided local search for graph paths, puzzle states, and routing problems.
- How deep it goes
- Defines neighbor-based improvement, gives pseudocode and implementations, then stops short of guaranteed global optimality.
- Examples
- Demonstrates route finding, an eight-puzzle solver, misplaced-tile costs, randomized routes, and neighborhood-size tuning.
- What you can do after
- Apply hill climbing by defining states, neighbors, and a cost function, then tuning neighborhood size for routing.
Advanced Algorithms and Data Structures
Hill climbing is an iterative local-search technique that moves from a candidate solution to a neighboring solution with an improved objective value.
- How it is used
- Improves approximate solutions for optimization problems such as graph layouts, routing, schedules, and component designs.
- How deep it goes
- Defines neighborhood exploration and improvement-based updates, then explains failure on local minima and plateaus.
- Examples
- Uses vertex movements in graph embeddings and a marble moving across a cost landscape.
- What you can do after
- Apply it to improve a computable objective when differentiability is unavailable, while recognizing approximate results.
Read how Advanced Algorithms and Data Structures explains hill climbing →
What to know first
- local optimumA local optimum is a feasible point whose objective value is no worse than that of sufficiently nearby feasible points, though a better point may exist elsewhere.
- global optimumA global optimum is a feasible point or solution whose objective value is at least as favorable as that of every other point or solution in the domain.
- search spaceA search space is the set of possible states, choices, configurations, or candidate solutions that may be considered when exploring or solving a problem.
Related concepts
- Pareto frontiercontrasts with · A Pareto frontier is the set of feasible solutions that are not dominated by any other solution across multiple objectives.
- searchkind of · Search is an optimization process that generates candidate artifact variants and selects among them according to a signal.
- local searchkind of · Local search is an optimization technique that iteratively explores neighboring candidate solutions to find an improved solution according to an objective or constraint measure.
- COPROused by · COPRO is a DSPy prompt-optimization technique that iteratively generates and evaluates alternative prompt instructions to improve their performance.
- archive searchcontrasts with · A search method that retains previously tried candidates and selects from the archive using criteria such as quality and diversity.
- evolutionary computationcontrasts with · Evolutionary computation is a family of search and optimization methods that iteratively improve candidate solutions through variation and selection inspired by biological evolution.
Questions about hill climbing
What is hill climbing?
Hill climbing is an iterative local-search optimization method that repeatedly moves from a candidate solution to a better neighboring solution.
Which Manning books explain hill climbing?
Self-Improving Agents, Optimization Algorithms: AI techniques for design, planning, and control problems and Advanced Algorithms and Data Structures.
What should I know before learning hill climbing?
Manning books that teach hill climbing usually introduce local optimum, differentiable, global optimum and search space first.
What is the difference between hill climbing and Pareto frontier?
Hill climbing is an iterative local-search optimization method that repeatedly moves from a candidate solution to a better neighboring solution. A Pareto frontier is the set of feasible solutions that are not dominated by any other solution across multiple objectives.
What is hill climbing a kind of?
Hill climbing is a kind of search. Search is an optimization process that generates candidate artifact variants and selects among them according to a signal.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.


