danielhanchen commited on
Commit
8d59da6
·
verified ·
1 Parent(s): 089fe7a

Upload folder using huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +125 -0
README.md ADDED
@@ -0,0 +1,125 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ tags:
3
+ - unsloth
4
+ base_model:
5
+ - internlm/JanusCoder-14B
6
+ license: apache-2.0
7
+ pipeline_tag: image-text-to-text
8
+ library_name: transformers
9
+ ---
10
+ > [!NOTE]
11
+ > Includes Unsloth **chat template fixes**! <br> For `llama.cpp`, use `--jinja`
12
+ >
13
+
14
+ <div>
15
+ <p style="margin-top: 0;margin-bottom: 0;">
16
+ <em><a href="https://docs.unsloth.ai/basics/unsloth-dynamic-v2.0-gguf">Unsloth Dynamic 2.0</a> achieves superior accuracy & outperforms other leading quants.</em>
17
+ </p>
18
+ <div style="display: flex; gap: 5px; align-items: center; ">
19
+ <a href="https://github.com/unslothai/unsloth/">
20
+ <img src="https://github.com/unslothai/unsloth/raw/main/images/unsloth%20new%20logo.png" width="133">
21
+ </a>
22
+ <a href="https://discord.gg/unsloth">
23
+ <img src="https://github.com/unslothai/unsloth/raw/main/images/Discord%20button.png" width="173">
24
+ </a>
25
+ <a href="https://docs.unsloth.ai/">
26
+ <img src="https://raw.githubusercontent.com/unslothai/unsloth/refs/heads/main/images/documentation%20green%20button.png" width="143">
27
+ </a>
28
+ </div>
29
+ </div>
30
+
31
+
32
+ # JanusCoder-14B
33
+
34
+ [💻Github Repo](https://github.com/InternLM/JanusCoder) • [🤗Model Collections](https://huggingface.co/collections/internlm/januscoder) • [📜Technical Report](https://www.arxiv.org/abs/2510.23538)
35
+
36
+ ## Introduction
37
+
38
+ We introduce JanusCoder and JanusCoderV, a suite of open-source foundational models designed to establish a unified visual-programmatic interface for code intelligence.
39
+ This model suite is built upon open-source language models (such as Qwen3-8B and 14B) and multimodal models (such as Qwen2.5-VL and InternVL3.5-8B). The JanusCoder series is trained on JANUSCODE-800K—the largest multimodal code corpus to date, generated by an innovative synthesis toolkit, covering everything from standard charts to complex interactive Web UIs and code-driven animations.
40
+ This enables the models to uniformly handle diverse visual-programmatic tasks, such as generating code from textual instructions, visual inputs, or a combination of both, rather than building specialized models for isolated tasks. JanusCoder excels at flexible content generation (like data visualizations and interactive front-ends) as well as precise, program-driven editing of visual effects and complex animation construction.
41
+
42
+ ## Model Downloads
43
+
44
+ | Model Name | Description | Download |
45
+ | --- | --- | --- |
46
+ | JanusCoder-8B | 8B text model based on Qwen3-8B. | 🤗 [Model](https://huggingface.co/internlm/JanusCoder-8B) |
47
+ | 👉 **JanusCoder-14B** | 14B text model based on Qwen3-14B. | 🤗 [Model](https://huggingface.co/internlm/JanusCoder-14B) |
48
+ | JanusCoderV-7B | 7B multimodal model based on Qwen2.5-VL-7B. | 🤗 [Model](https://huggingface.co/internlm/JanusCoderV-7B) |
49
+ | JanusCoderV-8B | 8B multimodal model based on InternVL3.5-8B. | 🤗 [Model](https://huggingface.co/internlm/JanusCoderV-8B) |
50
+
51
+ ## Performance
52
+
53
+ We evaluate the JanusCoder model on various benchmarks that span code interlligence tasks on multiple PLs:
54
+
55
+ | Model | JanusCoder-14B | Qwen3-14B | Qwen2.5-Coder-32B-Instruct | LLaMA3-8B-Instruct | GPT-4o |
56
+ | --- | --- | --- | --- | --- | --- |
57
+ | PandasPlotBench (Task) | 86 | 78 | 82 | 69 | 85 |
58
+ | ArtifactsBench | 41.1 | 36.5 | 35.5 | 36.5 | 37.9 |
59
+ | DTVBench (Manim) | 8.41 | 6.63 | 9.61 | 4.92 | 10.60 |
60
+ | DTVBench (Wolfram) | 5.97 | 5.08 | 4.98 | 3.15 | 5.97 |
61
+
62
+ ## Quick Start
63
+
64
+ **Transformers**
65
+
66
+ The following provides demo code illustrating how to generate text using JanusCoder-14B.
67
+
68
+ > Please use transformers >= 4.55.0 to ensure the model works normally.
69
+
70
+ ```python
71
+ from transformers import AutoTokenizer, AutoModelForCausalLM
72
+ import torch
73
+
74
+ model_name = "internlm/JanusCoder-14B"
75
+ tokenizer = AutoTokenizer.from_pretrained(model_name)
76
+ model = AutoModelForCausalLM.from_pretrained(model_name, device_map="auto", torch_dtype="auto")
77
+
78
+ messages = [
79
+ {
80
+ "role": "user",
81
+ "content": [
82
+ {"type": "text", "text": "Create a line plot that illustrates function y=x."},
83
+ ],
84
+ }
85
+ ]
86
+
87
+ inputs = tokenizer.apply_chat_template(messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt").to(model.device, dtype=torch.bfloat16)
88
+
89
+ generate_ids = model.generate(**inputs, max_new_tokens=32768)
90
+ decoded_output = processor.decode(generate_ids[0, inputs["input_ids"].shape[1] :], skip_special_tokens=True)
91
+ print(decoded_output)
92
+ ```
93
+
94
+ ## Citation
95
+ 🫶 If you are interested in our work or find the repository / checkpoints / benchmark / data helpful, please consider using the following citation format when referencing our papers:
96
+
97
+ ```bibtex
98
+ @article{sun2025januscoder,
99
+ title={JanusCoder: Towards a Foundational Visual-Programmatic Interface for Code Intelligence},
100
+ author={Sun, Qiushi and Gong, Jingyang and Liu, Yang and Chen, Qiaosheng and Li, Lei and Chen, Kai and Guo, Qipeng and Kao, Ben and Yuan, Fei},
101
+ journal={arXiv preprint arXiv:2510.23538},
102
+ year={2025}
103
+ }
104
+
105
+ @article{sun2024survey,
106
+ title={A survey of neural code intelligence: Paradigms, advances and beyond},
107
+ author={Sun, Qiushi and Chen, Zhirui and Xu, Fangzhi and Cheng, Kanzhi and Ma, Chang and Yin, Zhangyue and Wang, Jianing and Han, Chengcheng and Zhu, Renyu and Yuan, Shuai and others},
108
+ journal={arXiv preprint arXiv:2403.14734},
109
+ year={2024}
110
+ }
111
+
112
+ @article{chen2025interactscience,
113
+ title={InteractScience: Programmatic and Visually-Grounded Evaluation of Interactive Scientific Demonstration Code Generation},
114
+ author={Chen, Qiaosheng and Liu, Yang and Li, Lei and Chen, Kai and Guo, Qipeng and Cheng, Gong and Yuan, Fei},
115
+ journal={arXiv preprint arXiv:2510.09724},
116
+ year={2025}
117
+ }
118
+
119
+ @article{sun2025codeevo,
120
+ title={CodeEvo: Interaction-Driven Synthesis of Code-centric Data through Hybrid and Iterative Feedback},
121
+ author={Sun, Qiushi and Gong, Jinyang and Li, Lei and Guo, Qipeng and Yuan, Fei},
122
+ journal={arXiv preprint arXiv:2507.22080},
123
+ year={2025}
124
+ }
125
+ ```