A 100M-parameter transformer, trained fully from scratch, fine-tuned to generate a
complete Flutter/Dart file in one shot
from a natural-language goal. Pretrained on 2B tokens (70% Flutter/Dart code, 30% English text), then fine-tuned on 5M tokens of flat goal → complete-file examples (
bbidpa/flutter-full-examples-v1
).
This is one half of a paired comparison: this model is trained to emit the whole file directly, while its companion,
Rainbow-Pony-100M-Flutter-steps
, is trained to build the same kind of code up iteratively via a sequence of small diffs. Both were fine-tuned from the same pretrained checkpoint,
Rainbow-Pony-100M-Flutter-base
. The research question behind the pair: for a small model, is it more sample-efficient to learn "whole file in one pass," or "one small verifiable edit at a time"?
Prompts use a small XML-style tag vocabulary.
<CODE>
holds the current file contents (empty for a from-scratch generation),
<HISTORY>
holds prior steps (unused for this model's typical single-step usage, but part of the shared format), and the model completes everything after
<OUTPUT>
:
<GOAL>
Write a widget that displays a select button with months in it
</GOAL>
<CODE>
</CODE>
<HISTORY>
</HISTORY>
<OUTPUT>
Generate
defrender_step_prompt_from_data(
goal: str, code: str = "", history: list[dict] | None = None, action_type: str = "", action_desc: str = "", changes: list[dict] | None = None, is_last_step: bool = False, include_output: bool = False,
) -> str:
history = history or []
changes = changes or []
history_text = "\n".join(
f"<ACTION><TYPE>{h['type']}</TYPE><DESC>{h['desc']}</DESC></ACTION>"for h in history
)
text = f"""<GOAL>{goal}</GOAL><CODE>{code}</CODE><HISTORY>{history_text}</HISTORY><OUTPUT>"""if include_output:
hunks = "\n".join(
f"<HUNK>\n<SEARCH>\n{h['search']}\n</SEARCH>\n<REPLACE>\n{h['replace']}\n</REPLACE>\n</HUNK>"for h in changes
)
output = f"<ACTION><TYPE>{action_type}</TYPE><DESC>{action_desc}</DESC></ACTION>\n<CHANGES>\n{hunks}\n</CHANGES>"if is_last_step:
output += "\n<DONE></DONE>"
text += output + "\n</OUTPUT>"return text
defgenerate_output(model, tokenizer, device, prompt, max_new_tokens=300, **generate_kwargs):
prompt_ids = tokenizer.encode(prompt, add_special_tokens=False)
idx = torch.tensor([[tokenizer.bos_id] + prompt_ids], dtype=torch.long).to(device)
generated = model.generate(idx, max_new_tokens=max_new_tokens, eos_id=tokenizer.eos_id, **generate_kwargs)
text = tokenizer.decode(generated[0].tolist(), skip_special_tokens=False)
output = text.split("<OUTPUT>")[-1].split("</OUTPUT>")[0].strip()
return output
prompt = render_step_prompt_from_data(
goal="Write a widget that displays a select button with months in it",
)
text = generate_output(model, tokenizer, DEVICE, prompt, max_new_tokens=1024)
print(text)
Example
Input goal:
Write a widget that displays a select button with months in it
Output:
[paste your actual generated <ACTION>/<CHANGES> output here]
Training details
Architecture
100M-parameter decoder-only transformer, trained from scratch
Pretraining
2B tokens (70% Flutter/Dart code, 30% English text)
Rainbow-Pony-100m-Flutter-direct huggingface.co is an AI model on huggingface.co that provides Rainbow-Pony-100m-Flutter-direct's model effect (), which can be used instantly with this bbidpa Rainbow-Pony-100m-Flutter-direct model. huggingface.co supports a free trial of the Rainbow-Pony-100m-Flutter-direct model, and also provides paid use of the Rainbow-Pony-100m-Flutter-direct. Support call Rainbow-Pony-100m-Flutter-direct model through api, including Node.js, Python, http.
Rainbow-Pony-100m-Flutter-direct huggingface.co is an online trial and call api platform, which integrates Rainbow-Pony-100m-Flutter-direct's modeling effects, including api services, and provides a free online trial of Rainbow-Pony-100m-Flutter-direct, you can try Rainbow-Pony-100m-Flutter-direct online for free by clicking the link below.
bbidpa Rainbow-Pony-100m-Flutter-direct online free url in huggingface.co:
Rainbow-Pony-100m-Flutter-direct is an open source model from GitHub that offers a free installation service, and any user can find Rainbow-Pony-100m-Flutter-direct on GitHub to install. At the same time, huggingface.co provides the effect of Rainbow-Pony-100m-Flutter-direct install, users can directly use Rainbow-Pony-100m-Flutter-direct installed effect in huggingface.co for debugging and trial. It also supports api for free installation.
Rainbow-Pony-100m-Flutter-direct install url in huggingface.co: