diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index fb6b02b..488fd60 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -5,7 +5,3 @@ Let's not be too pretentious here (like most of the other projects implementing 1. Don't be an asshole and don't be annoying. 2. Follow the "contributing" guidelines in the README if you want to be a contributor. - -## **Acknowledgment** - -By contributing to this repository, you acknowledge the superiority of the maintainers, and recognize that any mistake on your part will reflect solely on your lack of worthiness. diff --git a/README.md.old b/README.md.old deleted file mode 100644 index 69af402..0000000 --- a/README.md.old +++ /dev/null @@ -1,135 +0,0 @@ -# Ollama Grid Search: Instantly Evaluate Multiple LLMs and Prompts. - - -This project automates the process of selecting the best models, prompts, or inference parameters for a given use-case, allowing you to iterate over their combinations and to visually inspect the results. - -It assumes [Ollama](https://www.ollama.ai) is installed and serving endpoints, either in `localhost` or in a remote server. - -Here's what an experiment for a simple prompt, tested on 3 different models, looks like: - -[Main Screenshot](./screenshots/main.png?raw=true) - -(For a more in-depth look at an evaluation process assisted by this tool, please check https://dezoito.github.io/2023/12/27/rust-ollama-grid-search.html). - -## Installation - -Check the [releases page](https://github.com/dezoito/ollama-grid-search/releases) for the project, or on the sidebar. - -## Features - -- Automatically fetches models from local or remote Ollama servers; -- Iterates over different models, prompts and parameters to generate inferences; -- A/B test different prompts on several models simultaneously; -- Allows multiple iterations for each combination of parameters; -- Allows [limited concurrency](https://dezoito.github.io/2024/03/21/react-limited-concurrency.html) **or** synchronous inference calls (to prevent spamming servers); -- Optionally outputs inference parameters and response metadata (inference time, tokens and tokens/s); -- Refetching of individual inference calls; -- Model selection can be filtered by name; -- List experiments which can be downloaded in JSON format; -- Experiments can be inspected in readable views; -- Re-run past experiments, cloning or modifying the parameters used in the past; -- Configurable inference timeout; -- Custom default parameters and system prompts can be defined in settings: - -[Settings](./screenshots/settings.png?raw=true) - -## Grid Search (or something similar...) - -Technically, the term "grid search" refers to iterating over a series of different model hyperparams to optimize model performance, but that usually means parameters like `batch_size`, `learning_rate`, or `number_of_epochs`, more commonly used in training. - -But the concept here is similar: - -Lets define a selection of models, a prompt and some parameter combinations: - -[gridparams](./screenshots/gridparams-animation.gif?raw=true) - -The prompt will be submitted once for each parameter **value**, for each one of the selected models, generating a set of responses. - - -## A/B Testing - -Similarly, you can perform A/B tests by selecting different models and compare results for the same prompt/parameter combination, or test different prompts under similar configurations: - -[A/B testing](./screenshots/ab-animation.gif?raw=true) - -Comparing the results of different prompts for the same model - -## Prompt Archive -You can save and manage your prompts (we want to make prompts compatible with [Open WebUI](https://github.com/open-webui/open-webui)) - -[Settings](./screenshots/prompt-archive.png?raw=true) - -You can **autocomplete** prompts by typing "/" (inspired by Open WebUI, as well): - -[A/B testing](./screenshots/autocomplete.gif?raw=true) - - - -## Experiment Logs - -You can list, inspect, or download your experiments: - -[Settings](./screenshots/experiments.png?raw=true) - -## Future Features - -- Grading results and filtering by grade -- Importing, exporting and sharing prompt lists and experiment parameters. - -## Contributing - -- For obvious bugs and spelling mistakes, please go ahead and submit a PR. - -- If you want to propose a new feature, change existing functionality, or propose anything more complex, please open an issue for discussion, **before** getting work done on a PR. - -## Development - -1. Make sure you have Rust installed. - -2. Clone the repository (or a fork) - -```sh -git clone https://github.com/dezoito/ollama-grid-search.git -cd ollama-grid-search -``` - -3. Install the frontend dependencies. - - ```sh - cd - # I'm using bun to manage dependencies, - # but feel free to use yarn or npm - bun install - ``` - -4. Make sure `rust-analyzer` is configured to run `Clippy` when checking code. - - If you are running VS Code, add this to your `settings.json` file - - ``` - { - ... - "rust-analyzer.check.command": "clippy", - } - ``` - - (or, better yet, just use the settings file provided with the code) - -5. Run the app in development mode - ```sh - cd / - bun tauri dev - ``` -6. Go grab a cup of coffee because this may take a while. - -## Citations - -The following works and theses have cited this repository: - -Inouye, D & Lindo, L, & Lee, R & Allen, E; Computer Science and Engineering Senior Theses: **Applied Auto-tuning on LoRA Hyperparameters** -Santa Clara University, 2024 - - -## Thank you! - -Huge thanks to [@FabianLars](https://github.com/FabianLars), [@peperroni21](https://github.com/pepperoni21) and [@TomReidNZ](https://github.com/TomReidNZ). diff --git a/notes.md b/notes.md index f92a111..9eb0e37 100644 --- a/notes.md +++ b/notes.md @@ -6,3 +6,25 @@ Note: `bun tauri dev` works on linux, but not on Macs right now.s fixes webkit bs in some linux instalations export WEBKIT_DISABLE_COMPOSITING_MODE=1 + +For Linux Mint 22 and Ubuntu 24, see this issue +https://github.com/tauri-apps/tauri/issues/9662 + +--- + +Workaround + +I worked around this by adding the following line to /etc/apt/sources.list: + +deb http://gb.archive.ubuntu.com/ubuntu jammy main + +Then doing: + +sudo apt update +sudo apt install libwebkit2gtk-4.0-dev + +--- + +# NO_PROXY: + +Make sure you have a `NO_PROXY` env var set to `localhost,127.0.0.1` diff --git a/src-tauri/src/main.rs b/src-tauri/src/main.rs index 9ab9be6..a3ead96 100644 --- a/src-tauri/src/main.rs +++ b/src-tauri/src/main.rs @@ -12,6 +12,7 @@ struct Payload { } fn main() { + // std::env::set_var("NO_PROXY", "127.0.0.1,localhost"); let builder = tauri::Builder::default().plugin(tauri_plugin_single_instance::init(|app, argv, cwd| { println!("{}, {argv:?}, {cwd}", app.package_info().name);