Skip to main content

LLM collaboration

Project description

model_collaboration

The future is now.

Contributors who just joined us, read this

Thank you for joining this effort! Kindly do the following:

  1. Get familiar with "Github Setup" in this readme: you need to create your own branch, code in your branch, and submit pull requests from your branch to the dev branch. Never edit anything on the dev branch.
  2. Follow "After that, quick start!!" in this readme.
  3. Read the beginning of model_collaboration/method/user_readme.md and briefly check out the methods we already have here.
  4. Follow model_collaboration/method/sample_approach.py and model_collaboration/method/developer_readme.md to develop your own method. Try to use the helper functions provided there if possible (such as distributed_generation.distributed_generation).
  5. After you implemented and tested your method, git add commit push, open a pull request from your branch to dev, assign your point of contact and Shangbin as the two reviewers.

Github Setup

  1. Clone the repo with https://github.com/BunsenFeng/model_collaboration.git.
  2. Checkout to the dev branch: git checkout dev
  3. Pull the latest changes from the dev branch to your local dev branch: git pull
  4. Create your own feature/hotfix branch on local: git checkout -b [your-local-branch-name]
  5. Make edits on the scripts you care.
  6. Push any changes you made on your local branch to the GitHub server - after git add and git commit operations, do git push, you will see git push --set-upstream origin [your-local-branch-name] suggested by github, copy and paste this command and run.
  7. Open a new Pull Request from the GitHub webpage, make sure it's merging from [your-local-branch-name] to the dev branch. Add any reviewer and Shangbin that matters to the changes.
  8. Once approved, merge the changes to the dev branch.
  9. After merging, you will see an option on the webpage to delete your own branch. Delete it.
  10. Loop from #2.

If you are in the middle of the development, and you need the latest changes from dev branch, follow the steps below:

  1. Keep track of the current changes you made on your local branch: git add and git commit your [your-local-branch-name]
  2. Checkout to the dev branch: git checkout dev
  3. Pull the latest changes from the dev branch: git pull
  4. Check back to your local branch: git checkout [your-local-branch-name]
  5. Merge the changes from dev branch to your own branch: git merge dev
  6. Keep working on your own branch. done.

Questions about git? Don't take guesses, email svenyan234@gmail.com and cc bunsenfeng@gmail.com.

After that, quick start!!

conda env create -f environment.yml
conda activate model_collaboration
cd ..
git clone https://github.com/arcee-ai/mergekit.git
cd mergekit
pip install -e .
cd ..
cd model_collaboration

Run your first model collaboration experiment (if you don't have 3 GPUs, go to test_config.json and set "gpu_ids": [0], [0,1], or whatever you have; if your GPU is nice, increase batch_size):

python -m model_collaboration.main -c model_collaboration/test_config.json

You will see the outputs and evaluation results in the model_collaboration/logs/ folder.

See model_collaboration/method/user_readme.md for more details about different collaboration methods implemented.

Zhaoxuan (our evaluation tsar), additionally see model_collaboration/data/eval_readme.md.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

modelco-0.0.1.4.tar.gz (11.3 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

modelco-0.0.1.4-py3-none-any.whl (11.4 MB view details)

Uploaded Python 3

File details

Details for the file modelco-0.0.1.4.tar.gz.

File metadata

  • Download URL: modelco-0.0.1.4.tar.gz
  • Upload date:
  • Size: 11.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.1

File hashes

Hashes for modelco-0.0.1.4.tar.gz
Algorithm Hash digest
SHA256 6c7ef6a86ce4828f54e4c56938f5f2cf4633a896b656e225b4f2ee2568e47e79
MD5 f9561fa8109d6209c5d2a1b2005c42f2
BLAKE2b-256 15e2cafe119743a13799d98936b369ac4f5d0004497bb5c8a6c00244a76945e8

See more details on using hashes here.

File details

Details for the file modelco-0.0.1.4-py3-none-any.whl.

File metadata

  • Download URL: modelco-0.0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 11.4 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.1

File hashes

Hashes for modelco-0.0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 b9ac2f271e99fd3afa310d3ece1068707116b4ec0112c3d0117c59045cfc1723
MD5 c0a84235d52c1b0c7e266e563f90cac0
BLAKE2b-256 b852d8a705bbc3c8eeea75f2bbe68479a99316d5d0181b03f183601b65f96279

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page