eokayakca commited on
Commit
9b2bd5f
·
verified ·
1 Parent(s): acb94fc

Upload folder using huggingface_hub

Browse files
README.md ADDED
@@ -0,0 +1,53 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ language:
3
+ - tr
4
+ - otk
5
+ tags:
6
+ - gokturk
7
+ - text-generation
8
+ - hobby
9
+ license: mit
10
+ ---
11
+
12
+ # Bitig-Nano
13
+
14
+ This is a small AI model that can write text in the Göktürk (Old Turkic) script. It was trained on the Turkish Wikipedia dataset, which was converted into Göktürk letters.
15
+
16
+ > [!IMPORTANT]
17
+ > **Disclaimer:** This project is for **fun and hobby purposes only**. It is not a professional tool. The model might make mistakes or write things that are not historically accurate. It is a "Nano" sized model created for educational experiments.
18
+
19
+ ## How to Use
20
+
21
+ You can use this model with the Python `transformers` library.
22
+
23
+ ```python
24
+ from transformers import GPT2LMHeadModel, PreTrainedTokenizerFast
25
+
26
+ model_name = "eokayakca/Bitig-Nano"
27
+
28
+ tokenizer = PreTrainedTokenizerFast.from_pretrained(model_name)
29
+ model = GPT2LMHeadModel.from_pretrained(model_name)
30
+
31
+ prompt = "𐱅𐰇𐰼" # Start with "Tür"
32
+ input_ids = tokenizer.encode(prompt, return_tensors="pt")
33
+
34
+ output = model.generate(input_ids, max_length=50)
35
+ generated_text = tokenizer.decode(output[0], skip_special_tokens=True)
36
+
37
+ # The output is in Logical Order (Left-to-Right).
38
+ # For correct display, you might need to reverse it to Right-to-Left.
39
+ print(f"Logical (LTR): {generated_text}")
40
+ print(f"Visual (RTL): {generated_text[::-1]}")
41
+ ```
42
+
43
+ ## About the Data
44
+
45
+ The model learned from Turkish Wikipedia articles. We changed the Latin letters to Göktürk letters using a custom converter script.
46
+
47
+ **Technical Note:** The text is stored in **Logical Order (Left-to-Right)** for Unicode compatibility. However, Göktürk script is historically written and read from **Right-to-Left**. When you view the output, you may need to reverse it visually.
48
+
49
+ ## Limitations
50
+
51
+ - The model is very small (Nano size).
52
+ - It may generate nonsense words or grammatically incorrect sentences.
53
+ - It is designed for testing and learning, not for serious translation or historical research.
added_tokens.json ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ {
2
+ "<|endoftext|>": 285
3
+ }
config.json ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "activation_function": "gelu_new",
3
+ "architectures": [
4
+ "GPT2LMHeadModel"
5
+ ],
6
+ "attn_pdrop": 0.1,
7
+ "bos_token_id": 0,
8
+ "embd_pdrop": 0.1,
9
+ "eos_token_id": 2,
10
+ "initializer_range": 0.02,
11
+ "layer_norm_epsilon": 1e-05,
12
+ "model_type": "gpt2",
13
+ "n_embd": 384,
14
+ "n_head": 6,
15
+ "n_inner": null,
16
+ "n_layer": 6,
17
+ "n_positions": 256,
18
+ "pad_token_id": 1,
19
+ "reorder_and_upcast_attn": false,
20
+ "resid_pdrop": 0.1,
21
+ "scale_attn_by_inverse_layer_idx": false,
22
+ "scale_attn_weights": true,
23
+ "summary_activation": null,
24
+ "summary_first_dropout": 0.1,
25
+ "summary_proj_to_labels": true,
26
+ "summary_type": "cls_index",
27
+ "summary_use_proj": true,
28
+ "torch_dtype": "float32",
29
+ "transformers_version": "4.52.4",
30
+ "use_cache": true,
31
+ "vocab_size": 8000
32
+ }
generation_config.json ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ {
2
+ "_from_model_config": true,
3
+ "bos_token_id": 0,
4
+ "eos_token_id": 2,
5
+ "pad_token_id": 1,
6
+ "transformers_version": "4.52.4"
7
+ }
merges.txt ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #version: 0.2
2
+ ð IJ
3
+ ðIJ °
4
+ Ġ Ġ
5
+ ðIJ° Ģ
6
+ ðIJ°Ģ ðIJ°
7
+ ĥ ðIJ°
8
+ ðIJ° ĥðIJ°
9
+ ðIJ° º
10
+ ĠĠ ĠĠ
11
+ ðIJ ±
12
+ ðIJ° Ĩ
13
+ ðIJ° ĩ
14
+ Ġ ðIJ°ĢðIJ°
15
+ ðIJ°Ĩ ðIJ°
16
+ £ ðIJ°ĢðIJ°
17
+ ² ðIJ°
18
+ ´ ðIJ°º
19
+ Ġ :
20
+ Ġ ðIJ°º
21
+ ðIJ° į
22
+ ðIJ°ĢðIJ° ¢
23
+ ðIJ°ĢðIJ° ĺ
24
+ ðIJ± ĥ
25
+ ðIJ± ĥðIJ°
model.safetensors ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:bbd3c1a2f371e24a6101de87edc10f8979c6d121f18e1386c8bafeab159508d4
3
+ size 55278960
special_tokens_map.json ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ {
2
+ "bos_token": "<s>",
3
+ "eos_token": "</s>",
4
+ "mask_token": "<mask>",
5
+ "pad_token": "<pad>",
6
+ "unk_token": "<unk>"
7
+ }
tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
tokenizer_config.json ADDED
@@ -0,0 +1,53 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "added_tokens_decoder": {
3
+ "0": {
4
+ "content": "<s>",
5
+ "lstrip": false,
6
+ "normalized": false,
7
+ "rstrip": false,
8
+ "single_word": false,
9
+ "special": true
10
+ },
11
+ "1": {
12
+ "content": "<pad>",
13
+ "lstrip": false,
14
+ "normalized": false,
15
+ "rstrip": false,
16
+ "single_word": false,
17
+ "special": true
18
+ },
19
+ "2": {
20
+ "content": "</s>",
21
+ "lstrip": false,
22
+ "normalized": false,
23
+ "rstrip": false,
24
+ "single_word": false,
25
+ "special": true
26
+ },
27
+ "3": {
28
+ "content": "<unk>",
29
+ "lstrip": false,
30
+ "normalized": false,
31
+ "rstrip": false,
32
+ "single_word": false,
33
+ "special": true
34
+ },
35
+ "4": {
36
+ "content": "<mask>",
37
+ "lstrip": false,
38
+ "normalized": false,
39
+ "rstrip": false,
40
+ "single_word": false,
41
+ "special": true
42
+ }
43
+ },
44
+ "bos_token": "<s>",
45
+ "clean_up_tokenization_spaces": false,
46
+ "eos_token": "</s>",
47
+ "extra_special_tokens": {},
48
+ "mask_token": "<mask>",
49
+ "model_max_length": 1000000000000000019884624838656,
50
+ "pad_token": "<pad>",
51
+ "tokenizer_class": "PreTrainedTokenizer",
52
+ "unk_token": "<unk>"
53
+ }
training_args.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:2e69ad3250b6174dc2a2582ab4078c80c27638de330a9511d7b48b1d50b2fbe8
3
+ size 5713
vocab.json ADDED
@@ -0,0 +1 @@
 
 
1
+ {"<s>":0,"<pad>":1,"</s>":2,"<unk>":3,"<mask>":4,"!":5,"\"":6,"#":7,"$":8,"%":9,"&":10,"'":11,"(":12,")":13,"*":14,"+":15,",":16,"-":17,".":18,"/":19,"0":20,"1":21,"2":22,"3":23,"4":24,"5":25,"6":26,"7":27,"8":28,"9":29,":":30,";":31,"<":32,"=":33,">":34,"?":35,"@":36,"A":37,"B":38,"C":39,"D":40,"E":41,"F":42,"G":43,"H":44,"I":45,"J":46,"K":47,"L":48,"M":49,"N":50,"O":51,"P":52,"Q":53,"R":54,"S":55,"T":56,"U":57,"V":58,"W":59,"X":60,"Y":61,"Z":62,"[":63,"\\":64,"]":65,"^":66,"_":67,"`":68,"a":69,"b":70,"c":71,"d":72,"e":73,"f":74,"g":75,"h":76,"i":77,"j":78,"k":79,"l":80,"m":81,"n":82,"o":83,"p":84,"q":85,"r":86,"s":87,"t":88,"u":89,"v":90,"w":91,"x":92,"y":93,"z":94,"{":95,"|":96,"}":97,"~":98,"¡":99,"¢":100,"£":101,"¤":102,"¥":103,"¦":104,"§":105,"¨":106,"©":107,"ª":108,"«":109,"¬":110,"®":111,"¯":112,"°":113,"±":114,"²":115,"³":116,"´":117,"µ":118,"¶":119,"·":120,"¸":121,"¹":122,"º":123,"»":124,"¼":125,"½":126,"¾":127,"¿":128,"À":129,"Á":130,"Â":131,"Ã":132,"Ä":133,"Å":134,"Æ":135,"Ç":136,"È":137,"É":138,"Ê":139,"Ë":140,"Ì":141,"Í":142,"Î":143,"Ï":144,"Ð":145,"Ñ":146,"Ò":147,"Ó":148,"Ô":149,"Õ":150,"Ö":151,"×":152,"Ø":153,"Ù":154,"Ú":155,"Û":156,"Ü":157,"Ý":158,"Þ":159,"ß":160,"à":161,"á":162,"â":163,"ã":164,"ä":165,"å":166,"æ":167,"ç":168,"è":169,"é":170,"ê":171,"ë":172,"ì":173,"í":174,"î":175,"ï":176,"ð":177,"ñ":178,"ò":179,"ó":180,"ô":181,"õ":182,"ö":183,"÷":184,"ø":185,"ù":186,"ú":187,"û":188,"ü":189,"ý":190,"þ":191,"ÿ":192,"Ā":193,"ā":194,"Ă":195,"ă":196,"Ą":197,"ą":198,"Ć":199,"ć":200,"Ĉ":201,"ĉ":202,"Ċ":203,"ċ":204,"Č":205,"č":206,"Ď":207,"ď":208,"Đ":209,"đ":210,"Ē":211,"ē":212,"Ĕ":213,"ĕ":214,"Ė":215,"ė":216,"Ę":217,"ę":218,"Ě":219,"ě":220,"Ĝ":221,"ĝ":222,"Ğ":223,"ğ":224,"Ġ":225,"ġ":226,"Ģ":227,"ģ":228,"Ĥ":229,"ĥ":230,"Ħ":231,"ħ":232,"Ĩ":233,"ĩ":234,"Ī":235,"ī":236,"Ĭ":237,"ĭ":238,"Į":239,"į":240,"İ":241,"ı":242,"IJ":243,"ij":244,"Ĵ":245,"ĵ":246,"Ķ":247,"ķ":248,"ĸ":249,"Ĺ":250,"ĺ":251,"Ļ":252,"ļ":253,"Ľ":254,"ľ":255,"Ŀ":256,"ŀ":257,"Ł":258,"ł":259,"Ń":260,"ðIJ":261,"ðIJ°":262,"ĠĠ":263,"ðIJ°Ģ":264,"ðIJ°ĢðIJ°":265,"ĥðIJ°":266,"ðIJ°ĥðIJ°":267,"ðIJ°º":268,"ĠĠĠĠ":269,"ðIJ±":270,"ðIJ°Ĩ":271,"ðIJ°ĩ":272,"ĠðIJ°ĢðIJ°":273,"ðIJ°ĨðIJ°":274,"£ðIJ°ĢðIJ°":275,"²ðIJ°":276,"´ðIJ°º":277,"Ġ:":278,"ĠðIJ°º":279,"ðIJ°į":280,"ðIJ°ĢðIJ°¢":281,"ðIJ°ĢðIJ°ĺ":282,"ðIJ±ĥ":283,"ðIJ±ĥðIJ°":284}