---
language:
- en
license: llama2
library_name: transformers
tags:
- code
- code-generation
- text-generation
- web-development
- react
- nextjs
- nodejs
- python
- typescript
- metadev
- fullstack
- conversational
pipeline_tag: text-generation
model-index:
- name: MetaDev-7B
results:
- task:
type: text-generation
name: Code Generation
dataset:
name: HumanEval
type: openai_humaneval
metrics:
- type: pass@1
value: 62.5
name: pass@1
- task:
type: text-generation
name: Code Generation
dataset:
name: MBPP
type: mbpp
metrics:
- type: pass@1
value: 58.3
name: pass@1
---

# MetaDev-7B
**Your Intelligent Coding Companion for Modern Web Development**
[Website](https://metadev.c) | [GitHub](https://github.com/metadev-xi/metadev7) | [Twitter](https://twitter.com/metadevxi)
🤗 [Hugging Face](https://huggingface.co/metadev7/metadev-7b) | 📄 License: Llama 2 Community
---
## Meet MetaDev-7B
Today, we release **MetaDev-7B** to the open-source community. This is more than just another code model—it's a specialized coding companion built from the ground up for modern web development.
MetaDev was built to shatter the stereotype that high-performance code assistants must remain behind closed doors. We have optimized the model specifically for **React, Next.js, Node.js, TypeScript**, and full-stack web development. From building responsive UI components to architecting secure REST APIs, MetaDev-7B empowers developers to build the next generation of web applications.
We believe powerful AI tools should be accessible to everyone. MetaDev-7B is our commitment to that future.
---
## How to Use
### Installation
```bash
pip install metadev-ai
```
### Quick Start
```python
from metadev import MetaDevModel
# Load model
model = MetaDevModel.from_pretrained("metadev7/metadev-7b")
# Generate code
response = model.generate("Create a React login form with validation")
print(response)
```
### Command Line Interface
```bash
# Interactive chat mode
metadev chat
# Generate code from prompt
metadev generate "Build a REST API with authentication"
# Review existing code
metadev review app.py
# Security audit
metadev audit auth.py --mode security
```
### API Server
```bash
# Start local API server
metadev serve --port 8000
```
---
## Benchmarks
MetaDev-7B delivers strong performance on core coding benchmarks, with particular strength in web development scenarios.
| Benchmark | MetaDev-7B | CodeLlama-7B | DeepSeek-Coder-6.7B | StarCoder2-7B |
|-----------|------------|--------------|---------------------|---------------|
| HumanEval | **62.5** | 53.7 | 60.6 | 57.2 |
| MBPP | **58.3** | 52.1 | 55.2 | 54.8 |
| Web Dev Benchmark | **78.9** | 45.2 | 52.3 | 48.7 |
| Security Awareness | **85.2** | 42.1 | 51.8 | 45.3 |
### Specialized Performance
We evaluated MetaDev-7B on domain-specific tasks critical to web development:
| Task | MetaDev-7B | CodeLlama-7B | DeepSeek-Coder |
|------|------------|--------------|----------------|
| React Component Generation | **82.0%** | 58.3% | 65.2% |
| API Endpoint Creation | **76.0%** | 52.1% | 61.8% |
| TypeScript Type Inference | **79.5%** | 48.7% | 68.3% |
| Security Best Practices | **85.0%** | 41.2% | 52.6% |
| Test Generation | **71.0%** | 45.8% | 58.2% |
| Documentation Quality | **74.3%** | 52.4% | 59.1% |
---
## Features
### Personality Modes
Switch between specialized modes for different tasks:
| Mode | Description | Use Case |
|------|-------------|----------|
| `default` | Balanced coding companion | General development |
| `teaching` | Patient instructor with explanations | Learning & onboarding |
| `security` | Security-first OWASP advisor | Security audits |
| `review` | Constructive code reviewer | Code reviews |
| `debugging` | Systematic problem solver | Bug fixing |
| `architect` | System design expert | Architecture decisions |
```python
# Switch modes
model = MetaDevModel.from_pretrained("metadev7/metadev-7b", mode="teaching")
```
### Framework Expertise
- **Frontend**: React, Next.js, Vue, Svelte, TypeScript
- **Backend**: Node.js, Express, FastAPI, Django
- **Database**: PostgreSQL, MongoDB, Prisma, Drizzle
- **DevOps**: Docker, GitHub Actions, Vercel, AWS
- **Testing**: Jest, Vitest, Pytest, Playwright
---
## Model Details
| Specification | Value |
|--------------|-------|
| Parameters | 7B |
| Architecture | LlamaForCausalLM |
| Context Length | 16,384 tokens |
| Precision | bfloat16 |
| Base Model | CodeLlama-7B |
| Fine-tuning | QLoRA (4-bit) |
| Training Data | 50K+ curated examples |
| Training Duration | 72 hours on 4x A100 |
### Hardware Requirements
| Precision | VRAM | RAM |
|-----------|------|-----|
| FP16 | 14GB | 16GB |
| 4-bit | 4GB | 8GB |
| 8-bit | 8GB | 12GB |
---
## Local Deployment
### Using Transformers
```python
from transformers import AutoModelForCausalLM, AutoTokenizer
tokenizer = AutoTokenizer.from_pretrained("metadev7/metadev-7b")
model = AutoModelForCausalLM.from_pretrained(
"metadev7/metadev-7b",
torch_dtype="auto",
device_map="auto"
)
inputs = tokenizer("Create a React button component", return_tensors="pt")
outputs = model.generate(**inputs, max_new_tokens=512)
print(tokenizer.decode(outputs[0]))
```
### Using vLLM
```bash
python -m vllm.entrypoints.openai.api_server \
--model metadev7/metadev-7b \
--dtype bfloat16
```
### Using Docker
```bash
docker pull metadev7/metadev-7b
docker run -p 8000:8000 --gpus all metadev7/metadev-7b
```
---
## Training
### Data Sources
- Curated GitHub repositories (⭐100+)
- Official framework documentation
- Stack Overflow (verified answers)
- Security-focused code reviews
- Production codebases (anonymized)
### Training Configuration
- **Method**: QLoRA with 4-bit quantization
- **LoRA Rank**: 64
- **Learning Rate**: 2e-4
- **Batch Size**: 4 (gradient accumulation: 4)
- **Epochs**: 3
- **Optimizer**: AdamW with cosine scheduler
---
## Limitations
- Optimized for web development (React, Node.js, Python, TypeScript)
- May require guidance for niche frameworks
- Not optimized for mobile (Swift/Kotlin) or game development
- Knowledge cutoff: October 2024
---
## License
MetaDev-7B is released under the **Llama 2 Community License**.
- ✅ Commercial use allowed
- ✅ Modification allowed
- ✅ Distribution allowed
- ⚠️ Must include original license
- ⚠️ 700M+ MAU requires special license from Meta
---
## Citation
```bibtex
@software{metadev2024,
title={MetaDev-7B: A Specialized Code Generation Model for Web Development},
author={MetaDev AI Team},
year={2024},
url={https://huggingface.co/metadev7/metadev-7b}
}
```
---
## Contact
- **Website**: [metadev.c](https://metadev.c)
- **GitHub**: [github.com/metadev-xi/metadev7](https://github.com/metadev-xi/metadev7)
- **Twitter**: [@metadevxi](https://twitter.com/metadevxi)
- **Email**: contact@metadev.c