Skip to content

Eine moderne Programmiersprache für KI-APIs. Kompiliert zu Rust für maximale Performance mit eingebauten Security- und ML-Features.

License

Notifications You must be signed in to change notification settings

SkyliteDesign/velinscript

🚀 VelinScript 3.1.0

██╗   ██╗███████╗██╗     ██╗███╗   ██╗    ███████╗ ██████╗██████╗ ██╗██████╗ ████████╗
██║   ██║██╔════╝██║     ██║████╗  ██║    ██╔════╝██╔════╝██╔══██╗██║██╔══██╗╚══██╔══╝
██║   ██║█████╗  ██║     ██║██╔██╗ ██║    ███████╗██║     ██████╔╝██║██████╔╝   ██║   
╚██╗ ██╔╝██╔══╝  ██║     ██║██║╚██╗██║    ╚════██║██║     ██╔══██╗██║██╔══██╗   ██║   
 ╚████╔╝ ███████╗███████╗██║██║ ╚████║    ███████║╚██████╗██║  ██║██║██║  ██║   ██║   
  ╚═══╝  ╚══════╝╚══════╝╚═╝╚═╝  ╚═══╝    ╚══════╝ ╚═════╝╚═╝  ╚═╝╚═╝╚═╝  ╚═╝   ╚═╝   
                                                                                        
                    V E L I N S C R I P T  3.1.0
                    Velisch - Eine moderne Programmiersprache für KI-APIs

Eine moderne Programmiersprache für KI-APIs, die zu Rust, PHP, Python, TypeScript, JavaScript, Go, Java und C# kompiliert.

English: A modern programming language for AI-APIs that compiles to Rust, PHP, Python, TypeScript, JavaScript, Go, Java, and C#.

Hinweis: Die Dokumentation ist derzeit nur auf Deutsch verfügbar. Englische Dokumentation folgt im nächsten Release.

Note: Documentation is currently available in German only. English documentation coming in the next release. License Rust Build Stars Forks Issues Contributors


🔗 Quick Links

📚 Dokumentation💬 Forum & Support📦 GitHub🐛 Issues💡 Discussions

Die Dokumentation enthält Tutorials, Quiz und interaktive Beispiele!


✨ Warum VelinScript? / Why VelinScript?

🇩🇪 Deutsch

  • KI-first, multi-target, production-ready Toolchain in 5 Minuten erlebbar
  • Hello-Wow-Endpoint mit Streaming, Metrics und Prompt-Optimizer
  • Kurz-Pitch, 3-Zeilen-Example, 5-Minuten-Tutorial: bauplan/VELINSCRIPT_PITCH_START.md

🇬🇧 English

  • AI-first, multi-target, production-ready toolchain experienceable in 5 minutes
  • Hello-Wow endpoint with streaming, metrics, and prompt optimizer
  • Short pitch, 3-line example, 5-minute tutorial: bauplan/VELINSCRIPT_PITCH_START.md

📊 GitHub Statistics

GitHub Stats Top Languages GitHub Streak


🎯 VelinScript 3.1.0 - Die Zukunft der KI-API-Entwicklung / The Future of AI-API Development

🇩🇪 Deutsch

VelinScript (Velisch) ist eine moderne, speziell für KI-API-Entwicklung optimierte Programmiersprache. Sie kombiniert die Einfachheit moderner Sprachen mit der Performance von Rust und bietet eine umfassende Toolchain für professionelle API-Entwicklung.

🇬🇧 English

VelinScript (Velisch) is a modern programming language specifically optimized for AI-API development. It combines the simplicity of modern languages with the performance of Rust and provides a comprehensive toolchain for professional API development.


🆕 Verbesserungen in Version 3.1.0 → Patch 0.5 / Improvements in Version 3.1.0 → Patch 0.5

🆕 Neu in Version 3.1.0 / New in Version 3.1.0

  • Multi-Target Compilation - Kompiliert zu Rust, PHP, Python, TypeScript, JavaScript, Go, Java, C#
    • Multi-Target Compilation - Compiles to Rust, PHP, Python, TypeScript, JavaScript, Go, Java, C#
  • Type Inference System - Automatische Type-Inference mit Member-Access und Result-Type-Auflösung
    • Type Inference System - Automatic type inference with member-access and result-type resolution
  • Automatic Code Ordering - Automatische Sortierung basierend auf Abhängigkeiten
    • Automatic Code Ordering - Automatic sorting based on dependencies
  • IR Representation - SSA-Format für optimierte Code-Generierung
    • IR Representation - SSA format for optimized code generation
  • Borrow Checker - Ownership & Borrowing System für Memory Safety
    • Borrow Checker - Ownership & borrowing system for memory safety
  • Prompt Optimizer - 90%+ Token-Ersparnis bei LLM-API-Calls
    • Prompt Optimizer - 90%+ token savings on LLM API calls
  • Vollständige CLI-Referenz - Alle Befehle dokumentiert
    • Complete CLI Reference - All commands documented
  • Vektor-Datenbanken - Vollständige Dokumentation für semantische Suche & RAG
    • Vector Databases - Complete documentation for semantic search & RAG

🆕 Neu in Version 3.0.1 / New in Version 3.0.1

  • IR Representation - SSA-Format für optimierte Code-Generierung
    • IR Representation - SSA format for optimized code generation
  • Borrow Checker - Ownership & Borrowing System
    • Borrow Checker - Ownership & borrowing system
  • Prompt Optimizer - 90%+ Token-Ersparnis
    • Prompt Optimizer - 90%+ token savings
  • KI-Compiler-Passes - Automatische Code-Analyse und -Generierung
    • AI Compiler Passes - Automatic code analysis and generation
  • System-Generierung - Boilerplate-freie Systeme
    • System Generation - Boilerplate-free systems
  • Automatische Parallelisierung - Multithreading, GPU, Async, SIMD
    • Automatic Parallelization - Multithreading, GPU, Async, SIMD

✨ Kernpunkte / Core Features

Feature Beschreibung / Description Status
🎯 KI-First Design Native Unterstützung für ML, LLM-Integration und Vector DBs / Native support for ML, LLM integration and vector DBs
Multi-Target Compilation Kompiliert zu 8 Zielsprachen / Compiles to 8 target languages
🔒 Security Eingebaute Security-Features / Built-in security features
🛠️ Developer Excellence Vollständige Toolchain / Complete toolchain
📚 Standard Library 50+ Module mit 200+ Funktionen / 50+ modules with 200+ functions
🧠 Type Inference Automatische Type-Erkennung / Automatic type inference
🔄 Code Ordering Automatische Sortierung / Automatic sorting
💾 Memory Safety Borrow Checker / Borrow checker

🤖 KI & Machine Learning Features

VelinScript 3.1.0 bietet native Unterstützung für moderne KI- und ML-Workflows:

LLM Integration

  • LLMClient: Native Unterstützung für OpenAI, Anthropic, Google Gemini und lokale LLMs
  • Embedding Generation: Automatische Embedding-Erstellung für Vector Search
  • Chat Completion: Einfache Integration von Chat-Funktionalitäten
  • Streaming Support: Echtzeit-Streaming von LLM-Responses
  • Prompt Optimizer: 90%+ Token-Ersparnis bei LLM-API-Calls

Vector Databases

  • VectorDB Support: Native Integration für Pinecone, Weaviate, Qdrant
  • Semantic Search: Embedding-basierte Ähnlichkeitssuche
  • RAG (Retrieval Augmented Generation): Vollständige RAG-Implementierung
  • Hybrid Search: Kombination aus Keyword- und Vector-Search
  • Automatic Indexing: Automatische Indexierung von Embeddings

Machine Learning

  • ModelLoader: Laden und Verwenden von ML-Models mit integriertem VelinLogger und Metrics
  • TrainingService: Framework für Model Training
    • ONNX Runtime Integration
    • TensorFlow Integration
    • Hyperparameter Tuning
    • Model Evaluation & Metrics
    • Model Versioning
    • Integriertes Logging und Performance Monitoring
  • LLMClient: Native LLM-Integration mit VelinLogger und Metrics
  • VectorDB: Vector Database Integration mit Monitoring und Error Handling
  • Inference Pipeline: Optimierte Inferenz-Pipelines
  • Model Versioning: Versionierung und Management von Models

Beispiel: LLM Chat API

@POST("/api/chat")
@Auth
fn chat(message: string): string {
    let client = LLMClient.new(LLMProvider::OpenAI, apiKey);
    let response = await client.complete({
        model: "gpt-4",
        messages: [{ role: "user", content: message }]
    });
    return response.content;
}

Beispiel: Vector Search & RAG

@POST("/api/search")
fn search(query: string): List<Document> {
    let llmClient = LLMClient.new(LLMProvider::OpenAI, apiKey);
    let vectorDB = VectorDB.new(VectorDBProvider::Pinecone, connectionString);
    
    // Embedding generieren
    let queryEmbedding = llmClient.embed(query);
    
    // Semantische Suche
    let results = vectorDB.search("documents", queryEmbedding, 10);
    
    return results.map(|r| db.find(Document, r.id));
}

🏗️ Core Features

Performance & Compilation

  • Multi-Target Compilation: Kompiliert zu 8 Zielsprachen
    • Rust (Default) - High-Performance, Type-Safe
    • PHP - Laravel, Symfony Support
    • Python - FastAPI, Flask Support
    • TypeScript/JavaScript - Express, NestJS Support
    • Go - Native Go Code Generation
    • Java - Spring Boot Support
    • C# - ASP.NET Core Support
  • Native Rust Compilation: VelinScript kompiliert zu optimiertem Rust-Code
  • Zero-Cost Abstractions: Moderne Sprachfeatures ohne Performance-Einbußen
  • Advanced Optimizer: ✅ Vollständig aktiviert - Function Inlining, Loop Unrolling, Dead Code Elimination, Constant Folding
  • IR Representation: SSA-Format für optimierte Code-Generierung
  • Borrow Checker: Ownership & Borrowing System für Memory Safety
  • Type Safety: Starke Typisierung mit Type Inference für bessere Entwicklererfahrung

Type System

  • Type Inference: Automatische Type-Inference mit Member-Access und Result-Type-Auflösung
  • Code Ordering: Automatische Sortierung von Funktionen, Typen und Blöcken basierend auf Abhängigkeiten
  • Result<T, E>: Explizite Fehlerbehandlung ohne Exceptions
  • Traits & Interfaces: Polymorphismus und Code-Wiederverwendung
  • Generics mit Constraints: Type-safe generische Programmierung
  • Pattern Matching: Erweiterte Pattern Matching mit Guards, Range Patterns und Destructuring

Standard Library

  • 50+ Module mit 200+ Funktionen für alle Anwendungsfälle
  • API Standard Library: Eingebaute Funktionen für REST-API-Entwicklung
  • Database Integration: Native Support für Datenbankoperationen (SeaORM, SQL)
  • Security Library: Production-Grade Auth mit JWT, OAuth2 und TOTP-Support ✅
  • ML Library: Echte Integration von OpenAI/Anthropic/Gemini und In-Memory Vector Search ✅
  • Vector Database Library: Integration für Vector Databases (Pinecone, Weaviate, Qdrant)
  • Collections Library: Umfangreiche Collections (List, Map, Set) mit funktionalen Methoden
  • HTTP Client Library: Vollständige Client-Library für HTTP-Requests
  • Rate Limiting: Erweiterte Rate Limiting Library mit verschiedenen Strategien (inkl. @RateLimit Decorator) ✅
  • VelinLogger: Strukturiertes Logging mit Context, JSON-Format und File-Rotation
  • Metrics Framework: Performance Monitoring mit Counters, Gauges und Histograms
  • VelinError: Umfassendes Error-Handling mit Context, Stack Traces und Recovery-Mechanismen

Vollständige Liste: Standard Library API Reference

Package Management

  • Integrierter Package Manager (velin-pkg): Dependency Management
  • Automatische Updates: Dependency Update Checking mit Breaking Change Detection
  • Security Auditing: Automatische Vulnerability-Erkennung

🎨 Language Features

Moderne Sprachkonstrukte

  • Result<T, E>: Explizite Fehlerbehandlung ohne Exceptions
  • Traits & Interfaces: Polymorphismus und Code-Wiederverwendung
  • Generics mit Constraints: Type-safe generische Programmierung
  • Pattern Matching: Erweiterte Pattern Matching mit Guards, Range Patterns und Destructuring
  • Closure/Lambda Functions: Funktionale Programmierung mit Type Inference
  • String Interpolation: Format-Strings mit {expression} Syntax

Erweiterte Pattern Matching

match (result) {
    Ok(value) if value > 0 => {
        return "positive";
    },
    0..=12 => {
        return "child";
    },
    "pending" | "processing" => {
        return "in progress";
    },
    User { name: "admin", role } => {
        return "admin access";
    },
    _ => {
        return "unknown";
    }
}

Closure/Lambda Functions

let add = (a: number, b: number) => a + b;
let doubled = list.map((x: number) => x * 2);
let evens = list.filter((x: number) => x % 2 == 0);

String Interpolation

let name = "John";
let age = 30;
let message = "Hello, {name}! You are {age} years old.";
// Ergebnis: "Hello, John! You are 30 years old."

let x = 10;
let y = 20;
let result = "Sum: {x + y}";
// Ergebnis: "Sum: 30"

🛠️ Developer Experience & Tools

Developer Tools

  • Linter (velin-lint): Code-Qualitätsanalyse mit Auto-Fix

    • Unused Variables Detection
    • Complexity Analysis
    • Naming Conventions
    • Erweiterte Regel-Architektur
  • AutoFix Engine: ✅

    • Automatische Fehlerkorrektur während der Kompilierung
    • Behebt unausgeglichene Klammern automatisch
    • Korrigiert fehlende Funktionssignaturen
    • Repariert unvollständige Generic-Typen
    • Aktivierbar mit --autofix Flag
  • Code Formatter: Vollständige Formatierung von VelinScript-Code

    • Konfigurierbare Formatierungsregeln
    • Unterstützung für alle Language Features
    • CLI-Integration (velin format)
  • Documentation Generator (velin-api-doc):

    • JSDoc-Parsing für /// Kommentare
    • HTML-Export
    • Interactive Docs (Swagger UI)
    • OpenAPI 3.0 Integration
  • Code Generation Tools: ✅

    • Boilerplate Generator: Automatische API- und CRUD-Code-Generierung
    • Client Generator: Generiert TypeScript/JavaScript/Rust Clients aus OpenAPI
    • Framework Selector: Automatische Erkennung und Codegen für alle unterstützten Frameworks
  • VelinAutoDoc: ✅

    • Automatische Dokumentationsgenerierung aus /// Doc-Comments
    • Strukturierte JSON-Exporte mit API-Dokumentation
    • LLM-freundliche Kontextinformationen für KI-gestützte Dokumentation
    • Integration mit @VelinAutoDoc Decorator
  • VelinAutoTest: ✅

    • Automatische Test-Generierung für Funktionen mit @VelinAutoTest
    • Generiert Mock-Daten basierend auf Funktionsparametern
    • Erstellt Test-Stubs mit grundlegenden Assertions
  • VelinInsight: ✅

    • Code-Analyse und Qualitätsprüfung
    • Erkennt ungenutzte Structs
    • Identifiziert komplexe Funktionen
    • Findet redundante Datenbank-Queries
  • VelinPipeline: ✅

    • Pipeline-Optimizer für Datenfluss-Analyse
    • Automatische Erkennung parallelisierbarer async Blöcke
    • Codegen-Optimierung mit tokio::join! für unabhängige Operationen
  • Hot Reload (velin-hot-reload):

    • Automatisches Neuladen bei Dateiänderungen
    • File System Watching
    • Watch-Mode und Server-Mode
  • Debugger (velin-debugger): DAP Server für Debugging

    • Breakpoints setzen/entfernen
    • Step Over/Into/Out
    • Variable Inspection
    • Call Stack Navigation
    • Watch Expressions
    • VS Code Integration
  • Security Scanner (velin-security):

    • Code-Scanning auf Security-Vulnerabilities
    • Dependency Vulnerability Scanner
    • CVE Database Integration (NVD API)
    • GitHub Security Advisories
    • OSV (Open Source Vulnerabilities) API

Language Server Protocol (LSP)

  • Auto-Completion: Intelligente Code-Vervollständigung
  • Go to Definition: Navigation zu Definitionen
  • Find All References: Alle Referenzen finden
  • Rename Symbol: Symbol-Umbenennung
  • Code Actions: Quick Fixes für häufige Fehler
  • Auto-Import Management: Automatische Import-Organisierung

VS Code Extension

Status: ✅ Vollständig implementiert

  • Syntax-Highlighting: Vollständige Unterstützung für alle VelinScript-Features
  • Code Snippets: Templates für @Flow, @VelinAutoDoc, @VelinPipeline, @VelinAutoTest, @VelinInsight
  • IntelliSense Support: Auto-Completion, Go to Definition, Find All References
  • Error Diagnostics: Echtzeit-Fehlererkennung
  • Code Formatting: Integrierte Formatierung
  • Debugger Integration (DAP): ✅
    • Breakpoints Management
    • Variable Inspection
    • Call Stack Navigation
    • Watch Expressions
  • Commands: 30+ Commands für Code-Generierung, Tests, Config, Backup, Rollback
  • LSP Integration: Language Server Protocol für erweiterte IDE-Features

Siehe: VS Code Extension Dokumentation

CLI-Referenz

Vollständige CLI-Referenz verfügbar: CLI-Referenz

Hauptbefehle:

  • velin compile - Kompilierung mit Multi-Target Support
  • velin check - Code-Prüfung (Parsing & Type Checking)
  • velin format - Code-Formatierung
  • velin serve / velin run - Development-Server
  • velin generate - Code-Generierung (API, CRUD, Client)
  • velin test - Tests ausführen
  • velin config - Config-Verwaltung
  • velin cache - Cache-Management
  • velin backup - Backup-Management
  • velin rollback - Rollback-Management

🔒 Security und Betrieb

Security Framework

  • @Auth Decorator: Automatische Authentifizierung
  • @Role Decorator: Role-based Access Control
  • Input Validation: Umfangreiches Validator Framework
  • Security Scanner (velin-security): Automatische Vulnerability-Erkennung
  • JWT/OAuth2: Native Unterstützung für moderne Auth-Protokolle

Rate Limiting

  • @RateLimit Decorator: Decorator-basierte Rate Limiting mit Type-Checker-Validierung ✅
    • Unterstützte Argumente: requests (number), window (string), strategy (string), key (string, optional)
    • Strategien: fixed-window, sliding-window, token-bucket
  • Fixed Window Strategy: Einfache Zeitfenster-basierte Begrenzung
  • Sliding Window Strategy: Gleitende Zeitfenster
  • Token Bucket Strategy: Token-basierte Rate Limiting
  • Distributed Rate Limiting: Redis-basierte verteilte Rate Limiting

Monitoring & Operations

  • Health Checks: Eingebaute Health-Monitoring mit HealthCheck Framework
  • VelinLogger: Strukturiertes Logging mit Context, JSON-Format, File-Rotation und Log-Levels
  • Metrics & Performance: MetricsCollector und PerformanceMonitor für Application Metrics
  • VelinError: Umfassendes Error-Handling mit Context, Stack Traces, Recovery-Mechanismen und Error Reporting
  • Backup & Rollback: Transaktions-Management mit Rollback-Support
  • VelinFlow Runtime: ✅
    • Automatisches State-Tracking für transaktionale Flows
    • Input-Snapshot-Management
    • Automatisches Rollback/Commit bei Erfolg/Fehler
    • Compensation-Logic für Self-Healing
    • Integration mit @Flow Decorator

🏛️ Architektur & Design

Modulare Architektur

VelinScript 3.1.0 folgt einer klaren, modularen Architektur für maximale Wartbarkeit und Skalierbarkeit:

velinscript/
├── compiler/                    # Compiler Implementation (Rust)
│   ├── src/
│   │   ├── compiler/            # Orchestrierung & Kontext
│   │   │   ├── orchestrator.rs  # Multi-File Dependency Management
│   │   │   ├── context.rs       # Shared Compilation Metadata
│   │   │   ├── config.rs        # Compiler Configuration
│   │   │   ├── pass.rs          # Pass Trait Definition
│   │   │   ├── language.rs      # Language Identity Validation
│   │   │   └── error.rs         # Compiler Errors
│   │   ├── passes/              # Compiler Passes (Pipeline)
│   │   │   ├── autofix.rs       # Pass 1: Syntax Auto-Correction
│   │   │   ├── parser.rs        # Pass 2: AST & Module Resolution
│   │   │   ├── desugar.rs       # Pass 2.5: Desugaring
│   │   │   ├── code_order.rs    # Pass 3: Dependency-based Sorting
│   │   │   ├── type_check.rs    # Pass 4: Type Inference & Checking
│   │   │   ├── codegen.rs       # Pass 5: Code Generation
│   │   │   ├── ai_semantic.rs   # AI: Semantic Analysis
│   │   │   ├── ai_bug_detection.rs  # AI: Bug Detection
│   │   │   ├── ai_codegen.rs    # AI: Code Generation
│   │   │   ├── ai_optimization.rs   # AI: Optimization
│   │   │   ├── ai_code_review.rs    # AI: Code Review
│   │   │   └── ai_sandbox.rs    # AI: Sandbox Testing
│   │   ├── parser/              # Parser Module (separate)
│   │   │   ├── lexer.rs         # Lexical Analysis
│   │   │   ├── parser.rs        # Syntax Parser
│   │   │   └── ast.rs           # Abstract Syntax Tree
│   │   ├── type_checker/        # Type System (separate)
│   │   │   ├── checker.rs       # Type Checker Implementation
│   │   │   ├── environment.rs   # Type Environment
│   │   │   └── errors.rs        # Type Errors
│   │   ├── borrow/              # Ownership & Lifetimes (separate)
│   │   │   ├── checker.rs       # Borrow Checker
│   │   │   ├── ownership.rs     # Ownership Rules
│   │   │   └── lifetime.rs      # Lifetime Analysis
│   │   ├── ir/                  # Intermediate Representation
│   │   │   ├── ir.rs            # IR Definition
│   │   │   ├── builder.rs       # IR Builder
│   │   │   ├── optimizer.rs     # IR Optimizer
│   │   │   └── validator.rs     # IR Validator
│   │   ├── codegen/             # Multi-Target Generatoren
│   │   │   ├── rust.rs          # Rust Backend
│   │   │   ├── typescript.rs    # TS/Express/NestJS Backend
│   │   │   ├── java.rs          # Java/Spring Backend
│   │   │   ├── csharp.rs        # C#/ASP.NET Backend
│   │   │   ├── python.rs        # Python Backend
│   │   │   ├── go.rs            # Go Backend
│   │   │   ├── php.rs           # PHP Backend
│   │   │   ├── javascript.rs    # JavaScript Backend
│   │   │   ├── openapi.rs       # OpenAPI Generator
│   │   │   ├── framework.rs     # Framework Detection
│   │   │   ├── infrastructure.rs # Infrastructure Code
│   │   │   ├── distributed.rs   # Distributed Systems
│   │   │   ├── system_generator.rs # System Generation
│   │   │   ├── autodoc.rs       # Auto Documentation
│   │   │   ├── autotest.rs      # Auto Test Generation
│   │   │   ├── boilerplate.rs   # Boilerplate Generation
│   │   │   ├── client.rs        # Client Generation
│   │   │   ├── ir_codegen.rs    # IR-based Codegen
│   │   │   ├── traits.rs        # Codegen Traits
│   │   │   └── templates/       # Code Templates
│   │   │       ├── api_server.rs
│   │   │       ├── auth.rs
│   │   │       ├── deployment.rs
│   │   │       ├── rate_limit.rs
│   │   │       └── ai_client.rs
│   │   ├── optimizer/           # Parallelisierung & Performance
│   │   │   ├── pipeline.rs      # Pipeline Optimization
│   │   │   ├── parallelization.rs # Parallelization Analysis
│   │   │   ├── profiling.rs     # Performance Profiling
│   │   │   └── learning.rs      # Learning-based Optimization
│   │   ├── analysis/            # Code Analysis
│   │   │   ├── insight.rs       # Code Insights
│   │   │   └── mod.rs
│   │   ├── autofix/             # Auto-Fix Module
│   │   │   ├── mod.rs
│   │   │   └── report.rs        # Fix Reports
│   │   ├── formatter/           # Code Formatter
│   │   │   ├── formatter.rs     # Formatting Logic
│   │   │   ├── config.rs        # Format Config
│   │   │   └── mod.rs
│   │   ├── prompt/              # AI Prompt Management
│   │   │   ├── optimizer.rs     # Prompt Optimization
│   │   │   ├── sanitizer.rs     # Prompt Sanitization
│   │   │   └── mod.rs
│   │   ├── error/               # Error Handling
│   │   │   └── suggestions.rs   # Error Suggestions
│   │   ├── stdlib/              # Standard Library (VelinScript)
│   │   │   ├── ml.rs            # LLM & AI Module
│   │   │   ├── llm.rs           # LLM Integration
│   │   │   ├── embedding.rs     # Embeddings
│   │   │   ├── nlp.rs           # NLP
│   │   │   ├── net.rs           # HTTP & Networking
│   │   │   ├── http.rs          # HTTP Client/Server
│   │   │   ├── http_client.rs   # HTTP Client
│   │   │   ├── websocket.rs     # WebSocket
│   │   │   ├── sys.rs           # System & Metrics
│   │   │   ├── metrics.rs       # Metrics
│   │   │   ├── logging.rs       # Logging
│   │   │   ├── tracing.rs       # Tracing
│   │   │   ├── process.rs       # Process Management
│   │   │   ├── env.rs           # Environment
│   │   │   ├── database.rs      # Database
│   │   │   ├── mongodb.rs       # MongoDB
│   │   │   ├── redis.rs         # Redis
│   │   │   ├── seaorm.rs        # SeaORM
│   │   │   ├── cache.rs         # Caching
│   │   │   ├── queue.rs         # Queue
│   │   │   ├── auth.rs          # Authentication
│   │   │   ├── oauth2.rs        # OAuth2
│   │   │   ├── security.rs      # Security
│   │   │   ├── encryption.rs    # Encryption
│   │   │   ├── crypto.rs        # Cryptography
│   │   │   ├── tls.rs           # TLS
│   │   │   ├── privacy.rs       # Privacy
│   │   │   ├── vault.rs         # Vault
│   │   │   ├── validation.rs    # Validation
│   │   │   ├── collections.rs   # Collections
│   │   │   ├── string.rs        # String Utils
│   │   │   ├── math.rs          # Math
│   │   │   ├── date.rs          # Date
│   │   │   ├── datetime.rs      # DateTime
│   │   │   ├── json.rs          # JSON
│   │   │   ├── yaml.rs          # YAML
│   │   │   ├── csv.rs           # CSV
│   │   │   ├── regex.rs         # Regex
│   │   │   ├── url.rs           # URL
│   │   │   ├── path.rs          # Path
│   │   │   ├── fileio.rs        # File I/O
│   │   │   ├── fs.rs            # Filesystem
│   │   │   ├── encoding.rs      # Encoding
│   │   │   ├── serialization.rs # Serialization
│   │   │   ├── template.rs      # Templates
│   │   │   ├── stream.rs       # Streams
│   │   │   ├── iterators.rs    # Iterators
│   │   │   ├── async_ops.rs    # Async Operations
│   │   │   ├── result.rs       # Result Types
│   │   │   ├── utils.rs        # Utilities
│   │   │   ├── extensions.rs   # Extensions
│   │   │   ├── flow.rs         # Control Flow
│   │   │   ├── workflow.rs     # Workflows
│   │   │   ├── scheduler.rs    # Scheduler
│   │   │   ├── event_bus.rs    # Event Bus
│   │   │   ├── api.rs          # API Utils
│   │   │   ├── config.rs       # Configuration
│   │   │   ├── fixtures.rs     # Test Fixtures
│   │   │   ├── mocks.rs        # Mocks
│   │   │   ├── testing.rs      # Testing
│   │   │   ├── test_module.rs  # Test Module
│   │   │   ├── sandbox.rs      # Sandbox
│   │   │   ├── audit.rs        # Audit
│   │   │   ├── alerting.rs     # Alerting
│   │   │   ├── backup.rs       # Backup
│   │   │   ├── rollback.rs     # Rollback
│   │   │   ├── rate_limit.rs   # Rate Limiting
│   │   │   ├── smtp.rs         # SMTP
│   │   │   ├── actix.rs        # Actix Framework
│   │   │   ├── axum.rs         # Axum Framework
│   │   │   ├── agent.rs        # Agent Framework
│   │   │   └── mod.rs
│   │   ├── cli.rs               # CLI Interface
│   │   ├── lib.rs               # Library Root
│   │   └── main.rs              # Binary Entry Point
│   └── Cargo.toml
├── tools/                       # CLI, LSP & Dev-Tools
│   ├── cli/                     # Command Line Interface
│   ├── lsp/                     # Language Server Protocol
│   ├── ide/                     # IDE Integration
│   ├── repl/                    # REPL
│   ├── debugger/                # Debugger
│   ├── profiler/                # Profiler
│   ├── linter/                  # Linter
│   ├── test-runner/             # Test Runner
│   ├── benchmark-runner/        # Benchmark Runner
│   ├── dependency-graph/        # Dependency Graph
│   ├── dead-code-detector/      # Dead Code Detector
│   ├── bundle-analyzer/         # Bundle Analyzer
│   ├── security-scanner/        # Security Scanner
│   ├── runtime-inspector/       # Runtime Inspector
│   ├── hot-reload/              # Hot Reload
│   ├── library-generator/       # Library Generator
│   ├── api-doc-generator/       # API Doc Generator
│   ├── package-manager/         # Package Manager
│   ├── example-plugin/          # Example Plugin
│   └── vscode-extension/        # VS Code Extension
├── docs/                        # Dokumentation
├── examples/                    # Beispiel-Projekte
├── tests/                       # Tests
└── README.md

Siehe: Compiler Architektur Dokumentation

Compiler Passes

VelinScript verwendet ein Pass-basiertes System mit 13 Compiler-Passes:

  1. AutoFixPass - Automatische Fehlerkorrektur
  2. ParserPass - Lexikalische und Syntax-Analyse
  3. DesugaringPass - Syntaktischer Zucker → Core-Syntax
  4. CodeOrderingPass - Automatische Sortierung basierend auf Abhängigkeiten
  5. AISemanticPass - KI-Semantik-Analyse
  6. AIBugDetectionPass - KI-Bug-Erkennung
  7. TypeCheckPass - Type Checking & Inference
  8. ParallelizationAnalyzer - Parallelisierungs-Analyse
  9. AICodeGenerationPass - KI-Code-Generierung
  10. AICodeReviewPass - KI-Code-Review
  11. AISandboxPass - KI-Sandbox-Testing
  12. AIOptimizationPass - KI-Optimierung
  13. CodegenPass - Multi-Target Code-Generierung

Siehe: Pass-Verlauf Dokumentation

Design-Prinzipien

  1. Einfachheit: Klare, lesbare Syntax
  2. Type Safety: Starke Typisierung mit Type Inference
  3. API-First: Built-in Support für REST APIs
  4. Security First: Security-Features von Anfang an
  5. KI/ML Ready: Native Unterstützung für KI/ML-Integration
  6. Multi-Target: Unterstützung für 8 Zielsprachen
  7. Performance: Zero-Cost Abstractions und Advanced Optimizer

🚀 Schnellstart

Voraussetzungen

  • Rust (Version 1.70 oder höher)
    • Installation: rustup.rs
    • Oder: curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

Installation

📦 Schritt 1: Repository klonen
$ git clone https://github.com/SkyliteDesign/velinscript.git
$ cd velinscript
🔨 Schritt 2: Compiler bauen
$ cd compiler
$ cargo build --release
🎯 Schritt 3: Neues Projekt erstellen
$ velin init my-project
$ cd my-project
✅ Schritt 4: Code prüfen
$ velin check -i main.velin
🔧 Schritt 5: Code kompilieren
# Zu Rust (Default)
$ velin compile -i main.velin

# Zu PHP
$ velin compile -i main.velin --target php

# Zu Python
$ velin compile -i main.velin --target python

📝 Beispiel

// Einfache API-Funktion
@GET("/api/hello")
fn hello(): string {
    return "Hello, VelinScript 3.1.0! 🚀";
}

// Mit Parametern, Validation und Rate Limiting
@POST("/api/users")
@Auth
@RateLimit(requests: 100, window: "1m", strategy: "fixed-window")
fn createUser(name: string, email: string): User {
    let user = User {
        id: generateId(),
        name: name,
        email: email,
        createdAt: datetime.now(),
    };
    return user;
}

// Struct-Definition
struct User {
    id: string,
    name: string,
    email: string,
}

// Result Type für explizite Fehlerbehandlung
fn parseNumber(input: string): Result<number, string> {
    // ... Parsing-Logik
}

// Pattern Matching
match (result) {
    Ok(value) => return value,
    Err(error) => return 0,
}

📚 Dokumentation

Getting Started

Architektur

Guides & Tutorials

Tools

Vollständige Dokumentation: docs/README.md


🌟 Showcase-Beispiele

🎯 Ultimate Showcase - Alle Features

Das ultimative Beispiel, das alle Features von VelinScript 3.1.0 demonstriert:

  • 📚 VelinAutoDoc: Automatische Dokumentationsgenerierung
  • ⚡ VelinPipeline: Automatische Parallelisierung
  • 🔄 @Flow: Transaktionales Flow-Management
  • 🏗️ Modulare Architektur: Saubere Trennung
  • 🔒 Production-Ready Security: Auth, RBAC, Validation
  • 🤖 KI-Integration: ML-Modelle nahtlos integriert

🎯 Custom Recommender - Hybrid Recommendation System

Production-ready Beispiel für ein intelligentes Recommendation System:

  • 🤖 Hybrid Algorithmus: Embedding-basierte + Collaborative Filtering
  • 🔍 Vector Database Integration: Pinecone, Weaviate, Qdrant
  • 🧠 LLM-Integration: OpenAI, Anthropic, Google Gemini
  • 🔒 Production-Ready Security: API Key Auth, Rate Limiting, CORS
  • 📊 Umfassende API: 5 Endpoints für Recommendations

Weitere Beispiele: examples/


⚠️ Reifegrad & Status

Aktueller Status: Beta (Production-Ready Features verfügbar)

VelinScript 3.1.0 ist in aktiver Entwicklung. Der Compiler-Kern ist funktionsfähig. Die Standard Library ist größtenteils nutzbar und getestet (50+ Module mit 200+ Funktionen).

✅ Was funktioniert zuverlässig

  • ✅ Parser für grundlegende Syntax (Funktionen, Structs, Enums, Decorators)
  • ✅ Type Checker mit Type Inference für einfache Typen und Standard Library Funktionen
  • ✅ Multi-Target Code Generation (Rust, PHP, Python, TypeScript, JavaScript, Go, Java, C#)
  • ✅ CLI-Befehle (compile, check, format, init, serve, generate, etc.)
  • ✅ String-Interpolation
  • ✅ Collections-Methoden (List.length(), List.join(), etc.)
  • ✅ Pattern Matching (grundlegend)
  • ✅ 50+ Standard Library Module mit 200+ Funktionen
  • ✅ AutoFix Engine
  • ✅ Developer Tools (Linter, Formatter, Debugger, Security Scanner, etc.)
  • ✅ VS Code Extension
  • ✅ LSP Server

Für Production-Use wird Beta-Status empfohlen.


🤝 Beitragen

Wir freuen uns über Beiträge! Bitte lese CONTRIBUTING.md für Details.

Entwicklung

# Repository klonen
git clone https://github.com/SkyliteDesign/velinscript.git
cd velinscript

# Compiler bauen
cd compiler
cargo build

# Tests ausführen
cargo test

# Code formatieren
cargo fmt

# Linter ausführen
cargo clippy

📄 Lizenz

Dieses Projekt ist unter der MIT-Lizenz lizenziert - siehe LICENSE für Details.


🔗 Links & Support


🙏 Danksagungen

VelinScript 3.1.0 wird von der Community entwickelt und verbessert. Vielen Dank an alle Contributors!

Contributors


Made with ❤️ by skylite.Design

Erfahren Sie mehr auf birdapi.de | Support im Forum | Dokumentation auf velinscript.birdapi.de

About

Eine moderne Programmiersprache für KI-APIs. Kompiliert zu Rust für maximale Performance mit eingebauten Security- und ML-Features.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Packages

No packages published

Languages