AutoTuner: A Self-Optimizing Algorithm Engine
Project description
๐ง AutoTuner: Intelligent Algorithm Recommender
AutoTuner is a smart algorithm recommendation engine that analyzes input data (arrays or graphs) and selects the most efficient algorithm based on structural and statistical features. It is designed to assist developers, educators, and learners in choosing optimal algorithms without manual trial and error.
โ ๏ธ Note: This is a beta release of Version 1.0 intended for testing.
๐ Please report any bugs or provide feedback to help improve stability and performance.
๐ Key Features
๐ Sorting Engine
Selects the most suitable sorting algorithm based on data features such as size, value range, and sortedness.
Algorithms supported:
- Insertion Sort
- Merge Sort
- Quick Sort
- Counting Sort
- TimSort
๐ธ๏ธ Graph Engine
Analyzes the graph's structure and properties to recommend ideal algorithms for traversal, shortest path, or cycle detection.
Algorithms supported:
- BFS
- DFS
- Dijkstra (Heap/Matrix)
- Topological Sort
- Cycle Detection
- Union-Find Cycle Check
Graph features detected:
- Directed/Undirected graphs
- Weighted/Unweighted edges
- Cycles
- Density and connectivity
๐ป CLI Tools
autotuner-sortโ Recommends and runs the best sorting algorithmautotuner-graphโ Detects graph type and runs the most suitable graph algorithm- Accepts JSON input for graphs
- Supports graph visualizations via
networkxandmatplotlib
๐ฆ Installation
git clone https://github.com/koushik-mahamkali/autotuner
cd autotuner-engine
pip install -e .
โ๏ธ Usage Examples
โ Sorting Example
autotuner-sort --input "[10, 3, 5, 1, 2]"
Expected Output:
โ
Recommended Algorithm: Quick Sort
โก๏ธ Sorted Output: [1, 2, 3, 5, 10]
๐ง Graph Analysis Example
Create a file named graph.json with the following content:
{
"directed": true,
"weighted": false,
"nodes": 4,
"edges": [[0, 1], [1, 2], [2, 3]]
}
Then run:
autotuner-graph --input graph.json
Expected Output (example):
๐ Graph Analysis Complete
โก๏ธ Detected: Directed, Unweighted, Acyclic
โ
Recommended Algorithm: Topological Sort
๐ง Behind the Scenes
AutoTuner uses a combination of feature extractors and rule-based heuristics to:
- Score array "sortedness"
- Detect graph density, direction, cycles, and edge weights
- Route the input to the optimal algorithm with explainability
๐ Project Structure
autotuner/
โโโ autotuner/
โ โโโ sort_engine.py
โ โโโ graph_engine.py
โ โโโ graph_features/
โ โโโ sort_features/
โ โโโ visualizers/
โ โโโ logger.py
โโโ cli/
โ โโโ autotuner_sort.py
โ โโโ autotuner_graph.py
โโโ examples/
โโโ tests/
โโโ README.md
๐ Visualization
AutoTuner generates clean and interpretable graph visualizations using:
networkxmatplotlib
โ Why Use AutoTuner?
- โ๏ธ Automation โ No need to guess; AutoTuner picks the best-fit algorithm
- ๐ Efficiency โ Decisions are based on key data features
- ๐จโ๐ซ Educational โ Understand why a specific algorithm fits your input
- ๐งฉ Extensible โ Add new algorithms or decision rules easily
๐ค Contributing
Contributions are welcome!
If you find bugs or want to enhance the engine, feel free to open an issue or submit a pull request.
๐ License
This project is licensed under the MIT License.
๐ฌ Contact
Krishna Koushik Mahamkali
๐ง LinkedIn
๐ GitHub Portfolio
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file autotuner_core-0.1.1.tar.gz.
File metadata
- Download URL: autotuner_core-0.1.1.tar.gz
- Upload date:
- Size: 15.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6236ced30a5d57709e5e90e943aac9d5d17564a4e1caaaaa4b21fdf40cf1294b
|
|
| MD5 |
f61079818d6cd84fa7af9710eaa38031
|
|
| BLAKE2b-256 |
d3f580fd15f9f2146a9a27f0f1136e9d037847168664e4a1a11afe7339d3f5c5
|
File details
Details for the file autotuner_core-0.1.1-py3-none-any.whl.
File metadata
- Download URL: autotuner_core-0.1.1-py3-none-any.whl
- Upload date:
- Size: 17.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c35d88f0b563ae7b87716354f143ced375a0c9dedbdd171ee807130bd0e2051d
|
|
| MD5 |
ec80fb13e21c8c5b553901e509ae6c5d
|
|
| BLAKE2b-256 |
d499d6ceb410e954326ef390ab6dff22662755e27e7e844f47b6104f77955a5f
|