Skip to content

Latest commit

 

History

History
373 lines (267 loc) · 7.48 KB

File metadata and controls

373 lines (267 loc) · 7.48 KB

Getting Started with Kodezi Chronos

Welcome to Kodezi Chronos! This guide will help you understand how to access and use the world's first debugging-first language model.

📋 Table of Contents

  1. Prerequisites
  2. Accessing Chronos
  3. Installation
  4. Basic Usage
  5. Integration Options
  6. Best Practices
  7. Troubleshooting
  8. Next Steps

Prerequisites

System Requirements

  • Operating System: Windows 10+, macOS 10.15+, Linux (Ubuntu 18.04+)
  • RAM: Minimum 8GB (16GB recommended)
  • Internet: Stable connection required
  • IDE Support: VS Code, IntelliJ IDEA, Visual Studio

Supported Languages

Currently supported:

  • Python (3.7+)
  • JavaScript/TypeScript
  • Java (8+)

Coming soon:

  • Go
  • Rust
  • C/C++

Accessing Chronos

1. Sign Up for Kodezi OS

Chronos is exclusively available through Kodezi OS:

  1. Visit https://kodezi.com/os
  2. Click "Get Early Access"
  3. Complete registration
  4. Availability: Q1 2026

2. Access Tiers

Tier Features Best For
Starter 100 debugs/month, Basic support Individual developers
Professional 1,000 debugs/month, Priority support Small teams
Enterprise Unlimited debugs, Dedicated support Large organizations

Installation

VS Code Extension

# Install from VS Code marketplace
code --install-extension kodezi.chronos-debugger

# Or search "Kodezi Chronos" in Extensions panel

IntelliJ Plugin

  1. Open IntelliJ IDEA
  2. Go to Settings → Plugins
  3. Search for "Kodezi Chronos"
  4. Click Install and restart

Command Line Interface

# Install via npm
npm install -g @kodezi/chronos-cli

# Or via pip
pip install kodezi-chronos

# Verify installation
chronos --version

Basic Usage

1. Debug a Simple Error

# Example: Python null pointer error
def process_user_data(user):
    # This will crash if user is None
    return user.name.upper()

# Trigger Chronos debugging
# In VS Code: Right-click on error → "Debug with Chronos"
# In CLI: chronos debug file.py --error "AttributeError"

Chronos will:

  1. Analyze the error context
  2. Identify root cause
  3. Propose a fix
  4. Validate with tests

2. Command Line Debugging

# Debug a specific file
chronos debug app.py

# Debug with error message
chronos debug app.js --error "TypeError: Cannot read property"

# Debug entire project
chronos debug . --deep

# Watch mode for continuous debugging
chronos watch src/ --auto-fix

3. IDE Integration

VS Code

  1. When an error occurs, click the 💡 lightbulb
  2. Select "Debug with Chronos"
  3. Review proposed fix
  4. Accept or modify

IntelliJ

  1. Right-click on error in editor
  2. Select "Chronos → Debug This Issue"
  3. View fix in diff view
  4. Apply with one click

Integration Options

1. CI/CD Pipeline

# GitHub Actions example
name: Chronos Auto-Debug
on:
  push:
    branches: [main, develop]
  
jobs:
  debug:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - uses: kodezi/chronos-action@v1
        with:
          api-key: ${{ secrets.CHRONOS_API_KEY }}
          auto-fix: true
          create-pr: true

2. Pre-commit Hook

# .git/hooks/pre-commit
#!/bin/bash
chronos lint --fix-errors
if [ $? -ne 0 ]; then
    echo "Chronos found and fixed errors. Please review changes."
    exit 1
fi

3. API Integration

from kodezi_chronos import ChronosClient

client = ChronosClient(api_key="your-api-key")

# Debug a code snippet
result = client.debug(
    code=buggy_code,
    error_message=error,
    context={"file_path": "app.py", "line": 42}
)

print(result.explanation)
print(result.fixed_code)

Best Practices

1. Provide Context

The more context you provide, the better Chronos performs:

# Good: Includes test case
def calculate_discount(price, discount_percent):
    return price * discount_percent  # Bug: should be (1 - discount_percent)

def test_calculate_discount():
    assert calculate_discount(100, 0.2) == 80  # Expects 20% off

2. Use Type Hints

Type hints help Chronos understand your code:

# Better debugging with types
from typing import List, Optional

def process_items(items: List[str]) -> Optional[str]:
    if not items:
        return None
    return items[0].upper()

3. Include Tests

Tests help Chronos validate fixes:

// function.js
function calculateTotal(items) {
    return items.reduce((sum, item) => sum + item.price);
}

// function.test.js
test('calculateTotal handles empty array', () => {
    expect(calculateTotal([])).toBe(0);  // This will help Chronos fix the bug
});

4. Review Before Applying

Always review Chronos's suggestions:

# Use diff mode to review
chronos debug file.py --diff

# Interactive mode
chronos debug file.py --interactive

Troubleshooting

Common Issues

1. "Chronos cannot access repository"

Solution: Ensure you're in a git repository or provide explicit path:

chronos debug --repo-path /path/to/repo

2. "Context too large"

Solution: Use focused debugging:

chronos debug specific_file.py --focus-on "function_name"

3. "Tests failing after fix"

Solution: Enable iterative mode:

chronos debug --iterative --max-attempts 5

Debug Logs

Enable verbose logging for troubleshooting:

# Set log level
export CHRONOS_LOG_LEVEL=DEBUG

# Or in command
chronos debug file.py --verbose

Configuration

Global Settings

Create ~/.chronos/config.yml:

# Chronos configuration
api_key: your-api-key
preferences:
  auto_fix: false
  create_tests: true
  explain_fixes: true
  max_iterations: 3
  
language_settings:
  python:
    style: pep8
    test_framework: pytest
  javascript:
    style: standard
    test_framework: jest

Project Settings

Create .chronos.yml in project root:

# Project-specific settings
exclude:
  - node_modules/
  - build/
  - "*.min.js"

rules:
  prefer_type_hints: true
  require_tests: true
  
custom_patterns:
  - pattern: "TODO"
    action: "ignore"

Next Steps

1. Explore Advanced Features

2. Learn from Examples

Check out our case studies:

3. Join the Community

Getting Help

Resources

Support Channels

Conclusion

You're now ready to start using Kodezi Chronos! Remember:

  1. ✅ Chronos is designed for debugging, not code generation
  2. ✅ It learns from your codebase over time
  3. ✅ Always review suggested fixes
  4. ✅ Use tests to validate changes

Happy debugging! 🚀