From d68c824d19cfbca4711e837337ce050cb827f5f0 Mon Sep 17 00:00:00 2001 From: Daniel King Date: Tue, 17 Oct 2023 16:14:53 -0700 Subject: [PATCH 1/4] add all models list and extra print --- scripts/misc/update_hub_code.py | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/scripts/misc/update_hub_code.py b/scripts/misc/update_hub_code.py index 9fbb76977f..e938eb204f 100644 --- a/scripts/misc/update_hub_code.py +++ b/scripts/misc/update_hub_code.py @@ -14,8 +14,24 @@ from llmfoundry.utils.huggingface_hub_utils import \ edit_files_for_hf_compatibility +_ALL_MODELS = [ + 'mosaicml/mpt-7b', + 'mosaicml/mpt-7b-instruct', + 'mosaicml/mpt-7b-chat', + 'mosaicml/mpt-30b', + 'mosaicml/mpt-30b-chat', + 'mosaicml/mpt-30b-instruct', + 'mosaicml/mpt-7b-8k', + 'mosaicml/mpt-7b-8k-instruct', + 'mosaicml/mpt-7b-8k-chat', + 'mosaicml/mpt-7b-storywriter', +] + def main(hf_repos_for_upload: List[str]): + if len(hf_repos_for_upload) == 0 and hf_repos_for_upload == ['all']: + hf_repos_for_upload = _ALL_MODELS + current_datetime = datetime.now() formatted_datetime = current_datetime.strftime('%B %d, %Y %H:%M:%S') @@ -62,6 +78,7 @@ def main(hf_repos_for_upload: List[str]): ) print(f'PR opened: {result}') + print() if __name__ == '__main__': From 5b6bf43bb5e00052eea67503c5e61ce3b8471a93 Mon Sep 17 00:00:00 2001 From: Daniel King Date: Tue, 17 Oct 2023 16:16:29 -0700 Subject: [PATCH 2/4] fix; --- scripts/misc/update_hub_code.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/misc/update_hub_code.py b/scripts/misc/update_hub_code.py index e938eb204f..708ff58b57 100644 --- a/scripts/misc/update_hub_code.py +++ b/scripts/misc/update_hub_code.py @@ -29,7 +29,7 @@ def main(hf_repos_for_upload: List[str]): - if len(hf_repos_for_upload) == 0 and hf_repos_for_upload == ['all']: + if len(hf_repos_for_upload) == 1 and hf_repos_for_upload == ['all']: hf_repos_for_upload = _ALL_MODELS current_datetime = datetime.now() From 5326cc4064d1f6613c5fd4a59c366a25c64aee1b Mon Sep 17 00:00:00 2001 From: Daniel King Date: Tue, 17 Oct 2023 16:16:55 -0700 Subject: [PATCH 3/4] fix --- scripts/misc/update_hub_code.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/misc/update_hub_code.py b/scripts/misc/update_hub_code.py index 708ff58b57..94005ced7d 100644 --- a/scripts/misc/update_hub_code.py +++ b/scripts/misc/update_hub_code.py @@ -29,7 +29,7 @@ def main(hf_repos_for_upload: List[str]): - if len(hf_repos_for_upload) == 1 and hf_repos_for_upload == ['all']: + if len(hf_repos_for_upload) == 1 and hf_repos_for_upload[0] == 'all': hf_repos_for_upload = _ALL_MODELS current_datetime = datetime.now() From 46388f768c4e5b764eb0b460256c7d9eb5567edb Mon Sep 17 00:00:00 2001 From: Daniel King <43149077+dakinggg@users.noreply.github.com> Date: Wed, 18 Oct 2023 13:42:41 -0700 Subject: [PATCH 4/4] Update scripts/misc/update_hub_code.py Co-authored-by: Mihir Patel --- scripts/misc/update_hub_code.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/misc/update_hub_code.py b/scripts/misc/update_hub_code.py index 94005ced7d..ee5f6935a3 100644 --- a/scripts/misc/update_hub_code.py +++ b/scripts/misc/update_hub_code.py @@ -77,8 +77,7 @@ def main(hf_repos_for_upload: List[str]): create_pr=True, ) - print(f'PR opened: {result}') - print() + print(f'PR opened: {result}\n') if __name__ == '__main__':