Made By
PolycoderReleased On
2008-08-27
PolyCoder is a large language model designed for code generation and understanding. It can be used for tasks such as auto-completion, code synthesis, code summarization, bug detection, and code review.
Key features:
- Available in three sizes: 160M, 400M, and 2.7B parameters
- Trained on 249 GB of code across 12 programming languages, including Python, JavaScript, Java, C, and C++
- Generates code snippets from prompts
- Provides perplexity scores for different programming languages to help understand model performance
How it works:
Users can load the model and tokenizer directly from the Hugging Face `transformers` library. Example usage:
```python
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("NinedayWang/PolyCoder-2.7B")
model = AutoModelForCausalLM.from_pretrained("NinedayWang/PolyCoder-2.7B")
prompt = '''def binarySearch(arr, left, right, x): mid = (left +'''
input_ids = tokenizer.encode(prompt, return_tensors='pt')
result = model.generate(input_ids, max_length=50, num_beams=4, num_return_sequences=4)
for res in result:
print(tokenizer.decode(res))
```
PolyCoder can also be run using Docker images for users with specific infrastructure needs.
Integrations:
- Fully integrated with the Hugging Face ecosystem
- Trained using the GPT-NeoX framework, which is based on Megatron and DeepSpeed
Use of AI:
PolyCoder leverages the GPT-2 architecture, known for its autoregressive capabilities, to generate coherent and contextually relevant code. It was trained on a large and diverse dataset of code from GitHub repositories.
AI foundation model:
PolyCoder is based on the GPT-2 architecture.
How to access:
- Accessible via the Hugging Face platform as a web app
- Can be integrated into applications using the Hugging Face API
- Available as Docker images for deployment in various environments
PolyCoder is ideal for developers looking to enhance productivity, educators teaching programming, researchers studying code generation models, and organizations implementing automated code review systems. It was launched in October 2022 and is available for use through the Hugging Face platform.
No hype. No doom. Just actionable resources and strategies to accelerate your success in the age of AI.
AI is moving at lightning speed, but we won’t let you get left behind. Sign up for our newsletter and get notified of the latest AI news, research, tools, and our expert-written prompts & playbooks.
AI is moving at lightning speed, but we won’t let you get left behind. Sign up for our newsletter and get notified of the latest AI news, research, tools, and our expert-written prompts & playbooks.