A collection of Artificial Intelligence algorithms implemented in Rust, covering graph search, maze solving, and agent-based decision making.
Implements classic graph search algorithms on a map of Latin and Central American countries. All algorithms search for a route from Argentina to the United States.
| Binary | Algorithm |
|---|---|
search_width |
Breadth-First Search (BFS) |
deep_search |
Depth-First Search (DFS) |
deep_search_limited |
Depth-Limited Search |
deeply_search_cost_limited |
Iterative Deepening DFS |
uniform_search |
Uniform Cost Search (Dijkstra's) |
greedy_search |
Greedy Best-First Search |
heuristic |
Heuristic Search |
a_star |
A* Search |
dea_star |
Dynamic Expected A* (DEA*) |
recursive_best_first |
Recursive Best-First Search (RBFS) |
bidireccional_search |
Bidirectional Search |
Run an algorithm:
cd graphs
cargo run --bin a_star
cargo run --bin uniform_search
# etc.Generates a random 30×30 maze and solves it using greedy best-first search with a Manhattan distance heuristic. The path goes from position (0,0) to (28,28). The solved maze is printed to the terminal with the route highlighted.
cd labyrinth
cargo runA smart agent that plays a "guess the number" game. The agent picks a random number between 1 and 100 and must find it using a binary search strategy informed by stored perceptions (previous guesses and their results: too high / too low).
cd ai-game
cargo run- Rust (edition 2021)
Each project is an independent Cargo workspace. Navigate into the desired subdirectory and run:
cargo build
cargo run