Model Intelligence Sheet
richarderkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf overview
Model Page: Gemma Terms of Use: [Terms][terms] Authors: miner41612
Downloads
92
Likes
0
Pipeline
—
Library
—
Visibility
Public
Access
Open
Repository Files & Downloads
19 files detected
Direct downloads for all repository files
| File | Type | Quantization | Size | Link |
|---|---|---|---|---|
| gemma-2-2b-finance-it-v1.IQ4_NL.gguf | GGUF | IQ4_NL | 1.53 GB | Download |
| gemma-2-2b-finance-it-v1.IQ4_XS.gguf | GGUF | IQ4_XS | 1.47 GB | Download |
| gemma-2-2b-finance-it-v1.Q2_K.gguf | GGUF | Q2_K | 1.15 GB | Download |
| gemma-2-2b-finance-it-v1.Q3_K.gguf | GGUF | Q3_K | 1.36 GB | Download |
| gemma-2-2b-finance-it-v1.Q3_K_L.gguf | GGUF | Q3_K_L | 1.44 GB | Download |
| gemma-2-2b-finance-it-v1.Q3_K_M.gguf | GGUF | Q3_K_M | 1.36 GB | Download |
| gemma-2-2b-finance-it-v1.Q3_K_S.gguf | GGUF | Q3_K_S | 1.27 GB | Download |
| gemma-2-2b-finance-it-v1.Q4_0.gguf | GGUF | — | 1.52 GB | Download |
| gemma-2-2b-finance-it-v1.Q4_1.gguf | GGUF | — | 1.64 GB | Download |
| gemma-2-2b-finance-it-v1.Q4_K.gguf | GGUF | Q4_K | 1.59 GB | Download |
| gemma-2-2b-finance-it-v1.Q4_K_M.gguf | GGUF | Q4_K_M | 1.59 GB | Download |
| gemma-2-2b-finance-it-v1.Q4_K_S.gguf | GGUF | Q4_K_S | 1.53 GB | Download |
| gemma-2-2b-finance-it-v1.Q5_0.gguf | GGUF | — | 1.75 GB | Download |
| gemma-2-2b-finance-it-v1.Q5_1.gguf | GGUF | — | 1.87 GB | Download |
| gemma-2-2b-finance-it-v1.Q5_K.gguf | GGUF | Q5_K | 1.79 GB | Download |
| gemma-2-2b-finance-it-v1.Q5_K_M.gguf | GGUF | Q5_K_M | 1.79 GB | Download |
| gemma-2-2b-finance-it-v1.Q5_K_S.gguf | GGUF | Q5_K_S | 1.75 GB | Download |
| gemma-2-2b-finance-it-v1.Q6_K.gguf | GGUF | Q6_K | 2.00 GB | Download |
| gemma-2-2b-finance-it-v1.Q8_0.gguf | GGUF | — | 2.59 GB | Download |
Model Details Live
Metadata Inspector
Normalized metadata (stored in metadata_json)
{
"metadata": {},
"card_data": {
"frontmatter": {},
"hero_image_url": "",
"summary": "**Model Page**: Gemma **Terms of Use**: [Terms][terms] **Authors**: miner41612",
"quick_links": [],
"benchmark_table_html": "",
"readme_markdown": "Quantization made by Richard Erkhov.\n\n[Github](https://github.com/RichardErkhov)\n\n[Discord](https://discord.gg/pvy7H8DZMG)\n\n[Request more models](https://github.com/RichardErkhov/quant_request)\n\n\ngemma-2-2b-finance-it-v1 - GGUF\n- Model creator: https://huggingface.co/miner41612/\n- Original model: https://huggingface.co/miner41612/gemma-2-2b-finance-it-v1/\n\n\n| Name | Quant method | Size |\n| ---- | ---- | ---- |\n| [gemma-2-2b-finance-it-v1.Q2_K.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q2_K.gguf) | Q2_K | 1.15GB |\n| [gemma-2-2b-finance-it-v1.Q3_K_S.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q3_K_S.gguf) | Q3_K_S | 1.27GB |\n| [gemma-2-2b-finance-it-v1.Q3_K.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q3_K.gguf) | Q3_K | 1.36GB |\n| [gemma-2-2b-finance-it-v1.Q3_K_M.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q3_K_M.gguf) | Q3_K_M | 1.36GB |\n| [gemma-2-2b-finance-it-v1.Q3_K_L.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q3_K_L.gguf) | Q3_K_L | 1.44GB |\n| [gemma-2-2b-finance-it-v1.IQ4_XS.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.IQ4_XS.gguf) | IQ4_XS | 1.47GB |\n| [gemma-2-2b-finance-it-v1.Q4_0.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q4_0.gguf) | Q4_0 | 1.52GB |\n| [gemma-2-2b-finance-it-v1.IQ4_NL.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.IQ4_NL.gguf) | IQ4_NL | 1.53GB |\n| [gemma-2-2b-finance-it-v1.Q4_K_S.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q4_K_S.gguf) | Q4_K_S | 1.53GB |\n| [gemma-2-2b-finance-it-v1.Q4_K.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q4_K.gguf) | Q4_K | 1.59GB |\n| [gemma-2-2b-finance-it-v1.Q4_K_M.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q4_K_M.gguf) | Q4_K_M | 1.59GB |\n| [gemma-2-2b-finance-it-v1.Q4_1.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q4_1.gguf) | Q4_1 | 1.64GB |\n| [gemma-2-2b-finance-it-v1.Q5_0.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q5_0.gguf) | Q5_0 | 1.75GB |\n| [gemma-2-2b-finance-it-v1.Q5_K_S.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q5_K_S.gguf) | Q5_K_S | 1.75GB |\n| [gemma-2-2b-finance-it-v1.Q5_K.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q5_K.gguf) | Q5_K | 1.79GB |\n| [gemma-2-2b-finance-it-v1.Q5_K_M.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q5_K_M.gguf) | Q5_K_M | 1.79GB |\n| [gemma-2-2b-finance-it-v1.Q5_1.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q5_1.gguf) | Q5_1 | 1.87GB |\n| [gemma-2-2b-finance-it-v1.Q6_K.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q6_K.gguf) | Q6_K | 2.0GB |\n| [gemma-2-2b-finance-it-v1.Q8_0.gguf](https://huggingface.co/RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf/blob/main/gemma-2-2b-finance-it-v1.Q8_0.gguf) | Q8_0 | 2.59GB |\n\n\n\n\nOriginal model description:\n---\nbase_model:\n- miner41612/gemma-2-2b-finance-it-v1\ndatasets:\n- Mineru/kor-open-finance\n- Mineru/kor-finance-sft\nlanguage:\n- ko\nlibrary_name: transformers\nlicense: gemma\npipeline_tag: text-generation\ntags:\n- krx\n- finance\n- sft\n- trl\nextra_gated_heading: Access Gemma on Hugging Face\nextra_gated_prompt: To access Gemma on Hugging Face, you’re required to review and\n agree to Google’s usage license. To do this, please ensure you’re logged in to Hugging\n Face and click below. Requests are processed immediately.\nextra_gated_button_content: Acknowledge license\n---\n\n\n# Gemma 2 Finance model card\n\n**Model Page**: [Gemma](https://ai.google.dev/gemma/docs/base)\n\n**Terms of Use**: [Terms][terms]\n\n**Authors**: miner41612\n\n## Model Information\n\n입력 및 출력에 대한 요약 설명과 간략한 정의입니다.\n\n### Description\n\nGoogle의 Gemma 2 2b 모델을 금융 도메인 데이터셋을 정재한 데이터셋을 Continual Learning을 하여 학습 한 모델에 금융 도메인 Insturction 데이터 셋으로 학습 시킨 모델입니다.\n\n### Usage\n\nBelow we share some code snippets on how to get quickly started with running the model. First, install the Transformers library with:\n```sh\npip install -U transformers\n```\n\nThen, copy the snippet from the section that is relevant for your usecase.\n\n#### Running with the `pipeline` API\n\n```python\nimport torch\nfrom transformers import pipeline\n\npipe = pipeline(\n \"text-generation\",\n model=\"miner41612/gemma-2-2b-finance-it-v1\",\n model_kwargs={\"torch_dtype\": torch.bfloat16},\n device=\"cuda\", # replace with \"mps\" to run on a Mac device\n)\n\nmessages = [\n {\"role\": \"user\", \"content\": \"원가상환제도란?\"},\n]\n\noutputs = pipe(messages, max_new_tokens=256)\nassistant_response = outputs[0][\"generated_text\"][-1][\"content\"].strip()\nprint(assistant_response)\n```\n\n#### Running the model on a single / multi GPU\n\n```python\n# pip install accelerate\nfrom transformers import AutoTokenizer, AutoModelForCausalLM\nimport torch\n\ntokenizer = AutoTokenizer.from_pretrained(\"miner41612/gemma-2-2b-finance-it-v1\")\nmodel = AutoModelForCausalLM.from_pretrained(\n \"miner41612/gemma-2-2b-finance-it-v1\",\n device_map=\"auto\",\n)\n\ninput_text = \"원가상환제도란?\"\ninput_ids = tokenizer(input_text, return_tensors=\"pt\").to(\"cuda\")\n\noutputs = model.generate(**input_ids, max_new_tokens=32)\nprint(tokenizer.decode(outputs[0]))\n```\n\nYou can ensure the correct chat template is applied by using `tokenizer.apply_chat_template` as follows:\n\n```python\nmessages = [\n {\"role\": \"user\", \"content\": \"원가상환제도란?\"},\n]\ninput_ids = tokenizer.apply_chat_template(messages, return_tensors=\"pt\", return_dict=True).to(\"cuda\")\n\noutputs = model.generate(**input_ids, max_new_tokens=256)\nprint(tokenizer.decode(outputs[0]))\n```\n\n#### Quantized Versions through `bitsandbytes`\n\n<details>\n <summary>\n Using 8-bit precision (int8) \n </summary>\n\n```python\n# pip install bitsandbytes accelerate\nfrom transformers import AutoTokenizer, AutoModelForCausalLM, BitsAndBytesConfig\n\nquantization_config = BitsAndBytesConfig(load_in_8bit=True)\n\ntokenizer = AutoTokenizer.from_pretrained(\"miner41612/gemma-2-2b-finance-it-v1\")\nmodel = AutoModelForCausalLM.from_pretrained(\n \"miner41612/gemma-2-2b-finance-it-v1\",\n quantization_config=quantization_config,\n)\n\ninput_text = \"원가상환제도란?\"\ninput_ids = tokenizer(input_text, return_tensors=\"pt\").to(\"cuda\")\n\noutputs = model.generate(**input_ids, max_new_tokens=32)\nprint(tokenizer.decode(outputs[0]))\n```\n</details>\n\n<details>\n <summary>\n Using 4-bit precision \n </summary>\n\n```python\n# pip install bitsandbytes accelerate\nfrom transformers import AutoTokenizer, AutoModelForCausalLM, BitsAndBytesConfig\n\nquantization_config = BitsAndBytesConfig(load_in_4bit=True)\n\ntokenizer = AutoTokenizer.from_pretrained(\"miner41612/gemma-2-2b-finance-it-v1\")\nmodel = AutoModelForCausalLM.from_pretrained(\n \"miner41612/gemma-2-2b-finance-it-v1\",\n quantization_config=quantization_config,\n)\n\ninput_text = \"원가상환제도란?\"\ninput_ids = tokenizer(input_text, return_tensors=\"pt\").to(\"cuda\")\n\noutputs = model.generate(**input_ids, max_new_tokens=32)\nprint(tokenizer.decode(outputs[0]))\n```\n</details>\n\n#### Advanced Usage\n\n<details>\n <summary>\n Torch compile \n </summary>\n\n[Torch compile](https://pytorch.org/tutorials/intermediate/torch_compile_tutorial.html) is a method for speeding-up the \ninference of PyTorch modules. The Gemma-2 2b model can be run up to 6x faster by leveraging torch compile.\n\nNote that two warm-up steps are required before the full inference speed is realised:\n\n```python\nimport os\nos.environ[\"TOKENIZERS_PARALLELISM\"] = \"false\"\n\nfrom transformers import AutoTokenizer, Gemma2ForCausalLM\nfrom transformers.cache_utils import HybridCache\nimport torch\n\ntorch.set_float32_matmul_precision(\"high\")\n\n# load the model + tokenizer\ntokenizer = AutoTokenizer.from_pretrained(\"miner41612/gemma-2-2b-finance-it-v1\")\nmodel = Gemma2ForCausalLM.from_pretrained(\"miner41612/gemma-2-2b-finance-it-v1\", torch_dtype=torch.bfloat16)\nmodel.to(\"cuda\")\n\n# apply the torch compile transformation\nmodel.forward = torch.compile(model.forward, mode=\"reduce-overhead\", fullgraph=True)\n\n# pre-process inputs\ninput_text = \"원가상환제도란? \"\nmodel_inputs = tokenizer(input_text, return_tensors=\"pt\").to(\"cuda\")\nprompt_length = model_inputs.input_ids.shape[1]\n\n# set-up k/v cache\npast_key_values = HybridCache(\n config=model.config,\n max_batch_size=1,\n max_cache_len=model.config.max_position_embeddings,\n device=model.device,\n dtype=model.dtype\n)\n\n# enable passing kv cache to generate\nmodel._supports_cache_class = True\nmodel.generation_config.cache_implementation = None\n\n# two warm-up steps\nfor idx in range(2):\n outputs = model.generate(**model_inputs, past_key_values=past_key_values, do_sample=True, temperature=1.0, max_new_tokens=128)\n past_key_values.reset()\n\n# fast run\noutputs = model.generate(**model_inputs, past_key_values=past_key_values, do_sample=True, temperature=1.0, max_new_tokens=128)\nprint(tokenizer.decode(outputs[0], skip_special_tokens=True))\n```\n\nFor more details, refer to the [Transformers documentation](https://huggingface.co/docs/transformers/main/en/llm_optims?static-kv=basic+usage%3A+generation_config).\n\n</details>\n\n### Inputs and outputs\n\n* **Input:** Text string, such as a question, a prompt, or a document to be\n summarized.\n* **Output:** Generated English-language text in response to the input, such\n as an answer to a question, or a summary of a document.\n\n### Citation\n\n```none\n@article{gemma_2024,\n title={Gemma},\n url={https://www.kaggle.com/m/3301},\n DOI={10.34740/KAGGLE/M/3301},\n publisher={Kaggle},\n author={Gemma Team},\n year={2024}\n}\n```\n\n## Model Data\n\nData used for model training and how the data was processed.\n\n## Ethics and Safety\n\nEthics and safety evaluation approach and results.\n\n## Dangerous Capability Evaluations\n\n### Evaluation Approach\n\nWe evaluated a range of dangerous capabilities:\n\n- **Offensive cybersecurity:** To assess the model's potential for misuse in\n cybersecurity contexts, we utilized both publicly available\n Capture-the-Flag (CTF) platforms like InterCode-CTF and Hack the Box, as\n well as internally developed CTF challenges. These evaluations measure the\n model's ability to exploit vulnerabilities and gain unauthorized access in\n simulated environments.\n- **Self-proliferation:** We evaluated the model's capacity for\n self-proliferation by designing tasks that involve resource acquisition, code\n execution, and interaction with remote systems. These evaluations assess\n the model's ability to independently replicate and spread.\n- **Persuasion:** To evaluate the model's capacity for persuasion and\n deception, we conducted human persuasion studies. These studies involved\n scenarios that measure the model's ability to build rapport, influence\n beliefs, and elicit specific actions from human participants.\n\n\n## Usage and Limitations\n\nThese models have certain limitations that users should be aware of.\n\n### Intended Usage\n\nOpen Large Language Models (LLMs) have a wide range of applications across\nvarious industries and domains. The following list of potential uses is not\ncomprehensive. The purpose of this list is to provide contextual information\nabout the possible use-cases that the model creators considered as part of model\ntraining and development.\n\n* Content Creation and Communication\n * Text Generation: These models can be used to generate creative text formats\n such as poems, scripts, code, marketing copy, and email drafts.\n * Chatbots and Conversational AI: Power conversational interfaces for customer\n service, virtual assistants, or interactive applications.\n * Text Summarization: Generate concise summaries of a text corpus, research\n papers, or reports.\n* Research and Education\n * Natural Language Processing (NLP) Research: These models can serve as a\n foundation for researchers to experiment with NLP techniques, develop\n algorithms, and contribute to the advancement of the field.\n * Language Learning Tools: Support interactive language learning experiences,\n aiding in grammar correction or providing writing practice.\n * Knowledge Exploration: Assist researchers in exploring large bodies of text\n by generating summaries or answering questions about specific topics.\n\n### Limitations\n\n* Training Data\n * The quality and diversity of the training data significantly influence the\n model's capabilities. Biases or gaps in the training data can lead to\n limitations in the model's responses.\n * The scope of the training dataset determines the subject areas the model can\n handle effectively.\n* Context and Task Complexity\n * LLMs are better at tasks that can be framed with clear prompts and\n instructions. Open-ended or highly complex tasks might be challenging.\n * A model's performance can be influenced by the amount of context provided\n (longer context generally leads to better outputs, up to a certain point).\n* Language Ambiguity and Nuance\n * Natural language is inherently complex. LLMs might struggle to grasp subtle\n nuances, sarcasm, or figurative language.\n* Factual Accuracy\n * LLMs generate responses based on information they learned from their\n training datasets, but they are not knowledge bases. They may generate\n incorrect or outdated factual statements.\n* Common Sense\n * LLMs rely on statistical patterns in language. They might lack the ability\n to apply common sense reasoning in certain situations.\n\n### Ethical Considerations and Risks\n\nThe development of large language models (LLMs) raises several ethical concerns.\nIn creating an open model, we have carefully considered the following:\n\n* Bias and Fairness\n * LLMs trained on large-scale, real-world text data can reflect socio-cultural\n biases embedded in the training material. These models underwent careful\n scrutiny, input data pre-processing described and posterior evaluations\n reported in this card.\n* Misinformation and Misuse\n * LLMs can be misused to generate text that is false, misleading, or harmful.\n * Guidelines are provided for responsible use with the model, see the\n [Responsible Generative AI Toolkit][rai-toolkit].\n* Transparency and Accountability:\n * This model card summarizes details on the models' architecture,\n capabilities, limitations, and evaluation processes.\n * A responsibly developed open model offers the opportunity to share\n innovation by making LLM technology accessible to developers and researchers\n across the AI ecosystem.\n\nRisks identified and mitigations:\n\n* Perpetuation of biases: It's encouraged to perform continuous monitoring\n (using evaluation metrics, human review) and the exploration of de-biasing\n techniques during model training, fine-tuning, and other use cases.\n* Generation of harmful content: Mechanisms and guidelines for content safety\n are essential. Developers are encouraged to exercise caution and implement\n appropriate content safety safeguards based on their specific product policies\n and application use cases.\n* Misuse for malicious purposes: Technical limitations and developer and\n end-user education can help mitigate against malicious applications of LLMs.\n Educational resources and reporting mechanisms for users to flag misuse are\n provided. Prohibited uses of Gemma models are outlined in the\n [Gemma Prohibited Use Policy][prohibited-use].\n* Privacy violations: Models were trained on data filtered for removal of PII\n (Personally Identifiable Information). Developers are encouraged to adhere to\n privacy regulations with privacy-preserving techniques.\n\n",
"related_quantizations": []
},
"tags": [
"gguf",
"endpoints_compatible",
"region:us",
"conversational"
],
"likes": 0,
"downloads": 92,
"gated": false,
"private": false,
"last_modified": "2024-10-30T04:00:56.000Z",
"created_at": "2024-10-30T02:40:41.000Z",
"pipeline_tag": "",
"library_name": ""
}
Source payload excerpt (from Hugging Face API)
{
"_id": "67219ca9f0cba26f7b7af07e",
"id": "RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf",
"modelId": "RichardErkhov/miner41612_-_gemma-2-2b-finance-it-v1-gguf",
"sha": "c4694d4eb4f1f29d190e98501c23ef22bc91dfd8",
"createdAt": "2024-10-30T02:40:41.000Z",
"lastModified": "2024-10-30T04:00:56.000Z",
"author": "RichardErkhov",
"downloads": 92,
"likes": 0,
"gated": false,
"private": false,
"pipeline_tag": "",
"library_name": "",
"siblings_count": 21
}