darkps commited on
Commit
2736e30
·
verified ·
1 Parent(s): 10188eb

Upload 2 files

Browse files
Files changed (2) hide show
  1. README.md +73 -3
  2. notebook.ipynb +102 -0
README.md CHANGED
@@ -1,3 +1,73 @@
1
- ---
2
- license: apache-2.0
3
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ language: multilingual
3
+ license: apache-2.0
4
+ author: DarkPs
5
+ library_name: transformers
6
+ tags:
7
+ - ice-ai
8
+ - ice-0001
9
+ - text-generation
10
+ - conversational
11
+ - programming
12
+ pipeline_tag: text-generation
13
+ ---
14
+
15
+ # ICE 0001
16
+
17
+ The "ice" model is a very robust, medium-sized model for human-like conversations, designed for quick chats and small code snippets.
18
+ ---
19
+
20
+ The ice model was released with massive equations:
21
+
22
+ ### Major Improvements
23
+
24
+ * It was trained on 5.47 billion Codex conversations.
25
+ * It was also trained on more than 30 billion human conversations to better adapt to different Arabic dialects and multiple languages.
26
+
27
+ ---
28
+
29
+ # Key Specifications
30
+
31
+ * **Model Family:** ICE AI
32
+ * **ID:** ice-0001
33
+ * **Model Size:** 8B Parameters
34
+ * **Context Length:** 32,768 tokens
35
+ * **Format:** Transformers
36
+ * **Inference Support:** CPU / GPU
37
+ * **Primary Focus:** Human-like conversational AI
38
+
39
+ ### Training
40
+
41
+ Trained on approximately **36 trillion tokens** across **119 languages and dialects**, with a strong focus on multiple Arabic dialects, international languages, and programming/code data.
42
+
43
+ ---
44
+
45
+ # Recommended Usage
46
+
47
+ ICE AI performs best when used for:
48
+
49
+ * General conversations
50
+ * multilingual chat
51
+ * Software development
52
+ * Code generation
53
+ * Code debugging
54
+ * Technical questions
55
+ * Scripting and automation
56
+ * Local offline AI deployment
57
+
58
+ ---
59
+
60
+ # ⚠️ Notes
61
+
62
+ * Designed for conversational and coding tasks.
63
+ * Output quality may vary depending on the quantization level and hardware.
64
+ * Best results are achieved with structured prompts.
65
+ * Larger context sizes may require substantial RAM/VRAM.
66
+
67
+ ---
68
+
69
+ # About Dark
70
+
71
+ DarkPs is an AI organization owned by FanuonAI, developing and maintaining open-source AI models such as DarkIT, ICE AI, and DarkCoder.
72
+
73
+ **Platform:** https://dark.ps
notebook.ipynb ADDED
@@ -0,0 +1,102 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "cells": [
3
+ {
4
+ "cell_type": "code",
5
+ "execution_count": null,
6
+ "metadata": {},
7
+ "outputs": [],
8
+ "source": [
9
+ "!pip install transformers accelerate torch huggingface_hub\n"
10
+ ]
11
+ },
12
+ {
13
+ "cell_type": "code",
14
+ "execution_count": null,
15
+ "metadata": {},
16
+ "outputs": [],
17
+ "source": [
18
+ "from huggingface_hub import HfApi\n",
19
+ "from transformers import AutoModelForCausalLM, AutoTokenizer\n",
20
+ "import torch\n",
21
+ "\n",
22
+ "ИДЕНТИФИКАТОР_РЕПО = \"darkps/ice-AI-transformers\"\n",
23
+ "\n",
24
+ "АПИ = HfApi()\n",
25
+ "\n",
26
+ "СПИСОК_ФАЙЛОВ = АПИ.list_repo_files(ИДЕНТИФИКАТОР_РЕПО)\n",
27
+ "\n",
28
+ "print(\"Файлы репозитория:\")\n",
29
+ "for файл in СПИСОК_ФАЙЛОВ:\n",
30
+ " print(файл)\n",
31
+ "\n",
32
+ "ТОКЕНИЗАТОР = AutoTokenizer.from_pretrained(\n",
33
+ " ИДЕНТИФИКАТОР_РЕПО,\n",
34
+ " trust_remote_code=True\n",
35
+ ")\n",
36
+ "\n",
37
+ "МОДЕЛЬ = AutoModelForCausalLM.from_pretrained(\n",
38
+ " ИДЕНТИФИКАТОР_РЕПО,\n",
39
+ " torch_dtype=torch.float16,\n",
40
+ " device_map=\"auto\",\n",
41
+ " trust_remote_code=True\n",
42
+ ")\n",
43
+ "\n",
44
+ "МОДЕЛЬ.eval()\n"
45
+ ]
46
+ },
47
+ {
48
+ "cell_type": "code",
49
+ "execution_count": null,
50
+ "metadata": {},
51
+ "outputs": [],
52
+ "source": [
53
+ "ЗАПРОС = \"Привет, как у тебя дела?\"\n",
54
+ "\n",
55
+ "СООБЩЕНИЯ = [\n",
56
+ " {\n",
57
+ " \"role\": \"user\",\n",
58
+ " \"content\": ЗАПРОС\n",
59
+ " }\n",
60
+ "]\n",
61
+ "\n",
62
+ "ТЕКСТ = ТОКЕНИЗАТОР.apply_chat_template(\n",
63
+ " СООБЩЕНИЯ,\n",
64
+ " tokenize=False,\n",
65
+ " add_generation_prompt=True\n",
66
+ ")\n",
67
+ "\n",
68
+ "ВХОДЫ = ТОКЕНИЗАТОР(\n",
69
+ " ТЕКСТ,\n",
70
+ " return_tensors=\"pt\"\n",
71
+ ").to(МОДЕЛЬ.device)\n",
72
+ "\n",
73
+ "with torch.no_grad():\n",
74
+ " ОТВЕТЫ = МОДЕЛЬ.generate(\n",
75
+ " **ВХОДЫ,\n",
76
+ " max_new_tokens=128,\n",
77
+ " temperature=0.7,\n",
78
+ " top_p=0.8,\n",
79
+ " top_k=20,\n",
80
+ " do_sample=True,\n",
81
+ " eos_token_id=ТОКЕНИЗАТОР.eos_token_id\n",
82
+ " )\n",
83
+ "\n",
84
+ "ОТВЕТ = ТОКЕНИЗАТОР.decode(\n",
85
+ " ОТВЕТЫ[0][ВХОДЫ.input_ids.shape[-1]:],\n",
86
+ " skip_special_tokens=True\n",
87
+ ")\n",
88
+ "\n",
89
+ "print(ОТВЕТ)\n"
90
+ ]
91
+ }
92
+ ],
93
+ "metadata": {
94
+ "kernelspec": {
95
+ "display_name": "Python 3",
96
+ "language": "python",
97
+ "name": "python3"
98
+ }
99
+ },
100
+ "nbformat": 4,
101
+ "nbformat_minor": 0
102
+ }