|
Download README.md from abdullahashraf122/nl2py-v2-code-translator: direct link, hf CLI and curl.
- Browser
- Download file 1.82 kB
-
https://huggingface.co/abdullahashraf122/nl2py-v2-code-translator/resolve/main/README.md
- Command line
-
hf download hf://abdullahashraf122/nl2py-v2-code-translator/README.md
-
curl -L -o README.md https://huggingface.co/abdullahashraf122/nl2py-v2-code-translator/resolve/main/README.md
1.82 kB
metadata
language:
- en
- py
license: mit
tags:
- code-generation
- t5
- text2text-generation
- python
pipeline_tag: text2text-generation
widget:
- text: 'translate English to Python: create a list of numbers from 1 to 10'
- text: 'translate English to Python: write a function that calculates factorial'
NL2Py v2: English-to-Python Neural Code Translator
Parent GitHub Repository: https://github.com/abdullah00ashraf/abdullah00ashraf
Ecosystem Documentation: Axiyon / Producttolaunch Catalog
Part of the Axiyon Research Ecosystem.
Author: Abdullah Ashraf (@abdullahashraf122)
GitHub Profile: https://github.com/abdullah00ashraf
Model Overview
NL2Py v2 is a specialized seq2seq transformer fine-tuned on the iamthedan/code-instructions-25k-python dataset with structural prompt prefixes (translate English to Python: ). It generates syntax-valid Python code snippets directly from natural language specifications.
Architecture Highlights
- Base Architecture: T5-small (60M parameters)
- Tokenizer: SentencePiece with custom prefix masking
- Max Length: 128 input tokens $\to$ 512 target tokens
- Loss Function: Cross-Entropy with label smoothing
Interactive Demo
Run the included app.py or execute the training pipeline via NL2Py_v2_Colab_Pipeline.ipynb.