self-discover  by catid

Google SELF-DISCOVER algorithm implementation

Created 1 year ago
299 stars

Top 89.0% on SourcePulse

GitHubView on GitHub
Project Summary

This repository implements Google's SELF-DISCOVER algorithm, a method for enabling large language models (LLMs) to autonomously discover and utilize tools. It's designed for researchers and developers looking to enhance LLM capabilities in complex problem-solving scenarios.

How It Works

SELF-DISCOVER employs a multi-stage process: SELECT, ADAPT, and IMPLEMENT. In the SELECT stage, the LLM identifies relevant tools or reasoning modules from a predefined set. The ADAPT stage refines these selections, tailoring them to the specific problem context. Finally, the IMPLEMENT stage generates a structured reasoning process, breaking down the problem and applying the adapted modules to arrive at a solution. This iterative refinement and structured approach aim to improve LLM reliability and transparency in tool use.

Quick Start & Requirements

  • Install:
    conda create -n sd python=3.10 -y
    conda activate sd
    git clone https://github.com/catid/self-discover.git
    cd self-discover
    pip install -r requirements.txt
    
  • Prerequisites: OpenAI API key (or compatible LLM endpoint), Python 3.10.
  • Demo: Edit self_discover.py with your API key and run python self_discover.py. The README provides an example output using a self-hosted Miqu 70B model on two 4090 GPUs.

Highlighted Details

  • Implements the algorithm from Google's research paper (arxiv.org/pdf/2402.03620.pdf).
  • Demonstrates a multi-stage reasoning process (SELECT, ADAPT, IMPLEMENT).
  • Provides a clear example of problem decomposition and tool selection for a math word problem.
  • Supports self-hosted models, as shown with the Miqu 70B example.

Maintenance & Community

The repository is maintained by catid. No specific community channels or roadmap details are provided in the README.

Licensing & Compatibility

The repository's license is not specified in the README.

Limitations & Caveats

The README does not specify the license, which may impact commercial use. The implementation relies on an external OpenAI API key or a compatible LLM, and successful execution may depend on the quality and capabilities of the chosen LLM.

Health Check
Last Commit

1 year ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
0
Star History
0 stars in the last 30 days

Explore Similar Projects

Starred by Vincent Weisser Vincent Weisser(Cofounder of Prime Intellect), Chip Huyen Chip Huyen(Author of "AI Engineering", "Designing Machine Learning Systems"), and
10 more.

tree-of-thought-llm by princeton-nlp

0.3%
6k
Research paper implementation for Tree of Thoughts (ToT) prompting
Created 2 years ago
Updated 8 months ago
Starred by Elie Bursztein Elie Bursztein(Cybersecurity Lead at Google DeepMind), Joe Walnes Joe Walnes(Head of Experimental Projects at Stripe), and
1 more.

KAG by OpenSPG

0.4%
8k
Logical reasoning framework for domain knowledge bases
Created 1 year ago
Updated 1 month ago
Feedback? Help us improve.