cfn-cerebras-code-generator

FAST code generation via Z.ai glm-4.6 model. Use for rapid test generation, boilerplate code, repetitive patterns, and bulk file creation. Ideal when speed matters more than nuance. Do NOT use for complex architectural decisions or security-critical code.

14 stars

Best use case

cfn-cerebras-code-generator is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

FAST code generation via Z.ai glm-4.6 model. Use for rapid test generation, boilerplate code, repetitive patterns, and bulk file creation. Ideal when speed matters more than nuance. Do NOT use for complex architectural decisions or security-critical code.

Teams using cfn-cerebras-code-generator should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/cfn-cerebras-code-generator/SKILL.md --create-dirs "https://raw.githubusercontent.com/masharratt/claude-flow-novice/main/.claude/cfn-extras/skills/deprecated/cfn-cerebras-code-generator/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/cfn-cerebras-code-generator/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How cfn-cerebras-code-generator Compares

Feature / Agentcfn-cerebras-code-generatorStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

FAST code generation via Z.ai glm-4.6 model. Use for rapid test generation, boilerplate code, repetitive patterns, and bulk file creation. Ideal when speed matters more than nuance. Do NOT use for complex architectural decisions or security-critical code.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

# Cerebras Code Generator Skill

## Description
Generates code using Z.ai glm-4.6 model for **fast test and code generation**. Use this for rapid iteration when generating tests, boilerplate, and repetitive code patterns.

## When to Use
- ✅ **Test generation** - unit tests, integration tests, test fixtures
- ✅ **Boilerplate code** - CRUD operations, API endpoints, data models
- ✅ **Repetitive patterns** - similar components, migration scripts
- ✅ **Bulk file creation** - generating multiple similar files quickly
- ❌ **NOT for** complex architecture, security-critical code, or nuanced logic

## Configuration
```bash
# Required environment variables
export ZAI_API_KEY="your-api-key"  # or CEREBRAS_API_KEY for legacy
export ZAI_MODEL="glm-4.6"  # Fast, cost-effective model

# Optional settings
export CEREBRAS_BASE_URL="https://api.cerebras.ai/v1"
export CONTEXT_DB_PATH="./.claude/skills/cfn-cerebras-code-generator/contexts.db"
```

## Usage

```bash
# Basic code generation
./generate-code.sh \
  --file-path "/path/to/file.ext" \
  --prompt "Create a REST API endpoint" \
  --context-files "src/models.py,src/utils.py"

# With explicit model
./generate-code.sh \
  --model "llama-3.1-70b" \
  --file-path "/path/to/file.py" \
  --prompt "Implement authentication middleware"
```

## Implementation Details

### Context Tracking
- Stores generation history in SQLite database
- Tracks what worked and what didn't
- Maintains conversation context
- Provides examples of successful patterns

### OpenAI Compatibility
- Uses OpenAI-compatible request/response format
- Supports streaming responses
- Handles token limits and rate limiting
- Automatic retry logic

### Features
- ✅ Visual diff generation
- ✅ Context file inclusion
- ✅ Error handling and validation
- ✅ Generation history tracking
- ✅ Success pattern learning
- ✅ Multiple model support

Related Skills

We are still matching the closest adjacent skills for this page. In the meantime, continue through the full directory.