title: Flutter Code Generator emoji: 💻 colorFrom: indigo colorTo: blue sdk: streamlit sdk_version: "1.18.1" app_file: app.py pinned: false
This project leverages Transformers and Hugging Face's Spaces to generate Flutter code based on user prompts. It is designed to simplify Flutter development by providing intelligent suggestions for UI and functionality implementations.
- Customizable Flutter Code Generation: Enter prompts like "Create a responsive login screen" to get Dart code snippets.
- Streamlit Web App: Interactive UI for generating Flutter code with adjustable parameters.
- Fine-tuned Model: Trained on multiple datasets for Flutter-specific code generation.
To run the app locally, follow these steps:
git clone https://github.com/cod-e-codes/flutter-code-generator.git
cd flutter-code-generator
pip install -r requirements.txt
streamlit run app.py
Adjust the following settings via the sidebar for code generation:
- Temperature: Controls randomness (higher = more random outputs).
- Top-p: Cumulative probability for nucleus sampling.
- Max Length: Maximum tokens in output.
- Repetition Penalty: Penalizes repetitive text.
- Top-k: Limits the sampling pool.
- Create a Hugging Face Space and select the "Streamlit" template.
- Upload the code files from this repository.
- Configure the environment by adding the required packages.
- Deploy and access the app via your Space's URL.
The model was fine-tuned using:
- Datasets from Hugging Face such as
wraps/codegen-flutter-v1
,limcheekin/flutter-website-3.7
, anddeepklarity/top-flutter-packages
. - A checkpoint from Salesforce's CodeGen model (
codegen-350M-mono
).
This project is open-source and available under the MIT License.
Built with ❤️ by Cod-e-Codes