Instructions to use GhostScientist/semanticwiki-coder-7b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use GhostScientist/semanticwiki-coder-7b with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("GhostScientist/semanticwiki-coder-7b", device_map="auto") - Notebooks
- Google Colab
- Kaggle
|
Download README.md from GhostScientist/semanticwiki-coder-7b: direct link, hf CLI and curl.
- Browser
- Download file 2.18 kB
-
https://huggingface.co/GhostScientist/semanticwiki-coder-7b/resolve/main/README.md
- Command line
-
hf download hf://GhostScientist/semanticwiki-coder-7b/README.md
-
curl -L -o README.md https://huggingface.co/GhostScientist/semanticwiki-coder-7b/resolve/main/README.md
2.18 kB
| base_model: Qwen/Qwen2.5-Coder-7B-Instruct | |
| library_name: transformers | |
| model_name: semanticwiki-coder-7b | |
| tags: | |
| - generated_from_trainer | |
| - trl | |
| - sft | |
| - hf_jobs | |
| - ml-intern | |
| licence: license | |
| # Model Card for semanticwiki-coder-7b | |
| This model is a fine-tuned version of [Qwen/Qwen2.5-Coder-7B-Instruct](https://huggingface.co/Qwen/Qwen2.5-Coder-7B-Instruct). | |
| It has been trained using [TRL](https://github.com/huggingface/trl). | |
| ## Quick start | |
| ```python | |
| from transformers import pipeline | |
| question = "If you had a time machine, but could only go to the past or the future once and never return, which would you choose and why?" | |
| generator = pipeline("text-generation", model="GhostScientist/semanticwiki-coder-7b", device="cuda") | |
| output = generator([{"role": "user", "content": question}], max_new_tokens=128, return_full_text=False)[0] | |
| print(output["generated_text"]) | |
| ``` | |
| ## Training procedure | |
| This model was trained with SFT. | |
| ### Framework versions | |
| - TRL: 1.13.0 | |
| - Transformers: 5.17.0 | |
| - Pytorch: 2.14.0 | |
| - Datasets: 5.0.1 | |
| - Tokenizers: 0.23.2 | |
| ## Citations | |
| Cite TRL as: | |
| ```bibtex | |
| @software{vonwerra2020trl, | |
| title = {{TRL: Transformers Reinforcement Learning}}, | |
| author = {von Werra, Leandro and Belkada, Younes and Tunstall, Lewis and Beeching, Edward and Thrush, Tristan and Lambert, Nathan and Huang, Shengyi and Rasul, Kashif and Gallouédec, Quentin}, | |
| license = {Apache-2.0}, | |
| url = {https://github.com/huggingface/trl}, | |
| year = {2020} | |
| } | |
| ``` | |
| <!-- ml-intern-provenance --> | |
| ## Generated by ML Intern | |
| This model repository was generated by [ML Intern](https://github.com/huggingface/ml-intern), an agent for machine learning research and development on the Hugging Face Hub. | |
| - Try ML Intern: https://smolagents-ml-intern.hf.space | |
| - Source code: https://github.com/huggingface/ml-intern | |
| ## Usage | |
| ```python | |
| from transformers import AutoModelForCausalLM, AutoTokenizer | |
| model_id = 'GhostScientist/semanticwiki-coder-7b' | |
| tokenizer = AutoTokenizer.from_pretrained(model_id) | |
| model = AutoModelForCausalLM.from_pretrained(model_id) | |
| ``` | |
| For non-causal architectures, replace `AutoModelForCausalLM` with the appropriate `AutoModel` class. | |