Web Analytics

AlphaEvolveWriting

⭐ 114 stars Hindi by tamassimonds

🌐 भाषा

AlphaEvolve Writing

AlphaEvolve Writing Process

आप पूरी व्याख्या यहाँ पा सकते हैं

आप एक प्रतियोगिता में प्रस्तुत की गई कहानी का उदाहरण यहाँ पा सकते हैं

एक आधुनिक, विकासवादी लेखन प्रणाली जो रचनात्मक कहानियाँ या सामान्य लेखन टुकड़े उत्पन्न, मूल्यांकन और विकसित करने के लिए एआई मॉडल का उपयोग करती है, जो पुनरावृत्त प्रतियोगिताओं के माध्यम से कार्य करती है। इसे आधुनिक डिजाइन सिद्धांतों का पालन करते हुए स्वच्छ, मॉड्यूलर Python आर्किटेक्चर के साथ बनाया गया है।

✨ विशेषताएँ

🚀 त्वरित शुरुआत

स्थापना

# Clone the repository
git clone https://github.com/your-org/alphaevolve-writing
cd alphaevolve-writing

Install with uv (recommended)

uv sync

Or install with pip

pip install -e .

Configure your API keys (see Configuration section below)

विकास चलाएं

# Run 5 evolution iterations
python evolve.py 5

Fresh start with 3 iterations

python evolve.py 3 --fresh

Use general writing mode

python evolve.py 5 --general

Show help

python evolve.py --help

🏗️ वास्तुकला

सिस्टम आधुनिक पायथन डिज़ाइन सिद्धांतों का पालन करता है जिसमें जिम्मेदारियों का स्पष्ट विभाजन है:

├── src/
│   ├── core/           # Pipeline orchestration
│   │   └── pipeline.py # Main EvolutionPipeline class
│   ├── generators/     # Story generation logic
│   │   ├── story_generator.py      # Initial & next batch generators
│   │   ├── generate_response.py    # Creative writing generation
│   │   ├── generate_response_general.py # General writing generation
│   │   └── judge_response.py       # AI judging system
│   ├── rankers/        # ELO ranking system
│   │   ├── elo_rank.py            # Core ELO algorithm
│   │   └── tournament_runner.py    # Tournament management
│   └── utils/          # Utility functions
│       └── inference.py           # Multi-provider LLM interface
├── evolve.py           # Clean CLI entry point
├── pyproject.toml      # Modern Python packaging
├── config.json         # Configuration
└── web_interface/      # Web UI for validation

मुख्य घटक

📖 यह कैसे काम करता है

सिस्टम तीन-चरणीय विकास चक्र का अनुसरण करता है:

1. प्रारंभिक बैच बनाएं

2. ELO टूर्नामेंट चलाएं

3. अगला बैच बनाएं

यह पुनरावृत्त प्रक्रिया समय के साथ लगातार बेहतर लेखन विकसित करती है।

⚙️ कॉन्फ़िगरेशन

बेसिक सेटअप

इन मुख्य फाइलों को संपादित करें:

API Keys सेटअप

सिस्टम कई एआई प्रदाताओं का समर्थन करता है जिन्हें config.json के माध्यम से कॉन्फ़िगर किया जाता है। कॉन्फ़िगरेशन मॉडल को प्रदाताओं से जोड़ता है और यह निर्दिष्ट करता है कि कौन से एनवायरनमेंट वेरिएबल्स में API Keys हैं:

{
  "llm_providers": {
    "openai": {
      "type": "openai",
      "base_url": "https://api.openai.com/v1",
      "api_key_env": "OPENAI_API_KEY"
    },
    "anthropic": {
      "type": "anthropic", 
      "api_key_env": "ANTHROPIC_API_KEY"
    },
    "deepinfra": {
      "type": "openai_compatible",
      "base_url": "https://api.deepinfra.com/v1/openai",
      "api_key_env": "DEEPINFRA_API_KEY"
    },
    "deepseek": {
      "type": "openai_compatible",
      "base_url": "https://api.deepseek.com/v1",
      "api_key_env": "DEEPSEEK_API_KEY"
    },
    "gemini": {
      "type": "openai_compatible",
      "api_key_env": "GEMINI_API_KEY",
      "base_url": "https://generativelanguage.googleapis.com/v1beta/openai/"
    }
  },
  "model_provider_mapping": {
    "gpt-4": "openai",
    "gpt-3.5-turbo": "openai", 
    "claude-3-sonnet-20240229": "anthropic",
    "meta-llama/Meta-Llama-3-70B-Instruct": "deepinfra",
    "deepseek-chat": "deepseek",
    "gemini-2.5-flash": "gemini"
  }
}
फिर अपनी API कुंजी को पर्यावरण वेरिएबल्स के रूप में सेट करें:

export OPENAI_API_KEY="your-openai-key"        # For GPT models
export ANTHROPIC_API_KEY="your-anthropic-key"  # For Claude models  
export DEEPINFRA_API_KEY="your-deepinfra-key"  # For Llama models
export DEEPSEEK_API_KEY="your-deepseek-key"    # For DeepSeek models
export GEMINI_API_KEY="your-gemini-key"          # For Gemini models
आपको केवल उन प्रदाताओं के लिए कुंजी सेट करने की आवश्यकता है जिन्हें आप उपयोग करने की योजना बना रहे हैं। सिस्टम स्वचालित रूप से कॉन्फ़िगरेशन के आधार पर मॉडल अनुरोधों को सही प्रदाता तक भेजता है।

कॉन्फ़िगरेशन विकल्प

config.json फ़ाइल संपूर्ण सिस्टम व्यवहार को नियंत्रित करती है:

{
  "batch_generation": {
    "num_stories": 10,
    "model": "gpt-4",
    "initial_elo": 1500
  },
  "elo_ranking": {
    "tournament_rounds": 50,
    "judge_model": "claude-3-sonnet-20240229",
    "k_factor": 32
  },
  "next_batch_generation": {
    "top_stories_to_select": 3,
    "variants_per_story": 2,
    "include_original_stories": true
  },
  "evolution_pipeline": {
    "max_iterations": 5,
    "auto_continue_from_existing": true
  }
}

🎭 लेखन मोड

क्रिएटिव राइटिंग मोड (डिफ़ॉल्ट)

सामान्य लेखन मोड (--general)

🔧 उन्नत कॉन्फ़िगरेशन

जनरेशन रणनीतियों को अनुकूलित करना

उन्नत उपयोगकर्ताओं के लिए, आप src/generators/ निर्देशिका में फ़ाइलों को संपादित कर जनरेशन प्रॉम्प्ट, लेखक शैलियाँ और मिशन सेट कस्टमाइज़ कर सकते हैं:

#### क्रिएटिव राइटिंग कस्टमाइज़ेशन (src/generators/generate_response.py)

मिशन सेट - रचनात्मक दृष्टिकोण और लक्ष्यों को परिभाषित करें:

mission_sets = {
    "emotional_depth": [
        "Focus on the psychological depth of characters",
        "Explore complex emotional landscapes", 
        "Create moments of genuine human connection"
    ],
    "narrative_craft": [
        "Experiment with unique narrative structures",
        "Use vivid, sensory descriptions",
        "Create compelling story arcs"
    ],
    "dialogue_mastery": [
        "Write authentic, character-specific dialogue",
        "Use subtext and implied meaning",
        "Balance dialogue with action and description"
    ]
}
लेखक शैलियाँ - विभिन्न लेखन दृष्टिकोणों की नकल करें:

author_styles = [
    "Write with the psychological insight of Virginia Woolf",
    "Adopt the sparse, powerful prose of Ernest Hemingway", 
    "Use the magical realism style of Gabriel García Márquez",
    "Employ the detailed world-building of Tolkien"
]
#### सामान्य लेखन अनुकूलन (src/generators/generate_response_general.py)

शैक्षणिक फोकस क्षेत्र - विशिष्ट लेखन डोमेन को लक्षित करें:

academic_focuses = [
    "Rigorous analytical argument development",
    "Clear thesis statement and supporting evidence",
    "Proper academic citation and source integration",
    "Logical flow and coherent structure"
]
लेखन दृष्टिकोण - विश्लेषणात्मक रणनीतियों को परिभाषित करें:

writing_approaches = [
    "Comparative analysis with multiple perspectives",
    "Problem-solution framework with evidence",
    "Cause-and-effect reasoning with examples",
    "Critical evaluation with balanced arguments"
]

जज मानदंड को अनुकूलित करना (src/generators/judge_response.py)

आप लेखन की गुणवत्ता के विशिष्ट पहलुओं पर ध्यान केंद्रित करने के लिए जजिंग मानदंड और मूल्यांकन प्रॉम्प्ट्स को संशोधित कर सकते हैं:

# Edit the judge_responses function to customize evaluation criteria
evaluation_criteria = [
    "Technical writing proficiency",
    "Creative originality and innovation", 
    "Emotional impact and reader engagement",
    "Structural coherence and flow",
    "Character development and authenticity"
]

उन्नत कॉन्फ़िगरेशन के लिए सुझाव

यह मॉड्यूलर दृष्टिकोण आपको अपने विशिष्ट लेखन लक्ष्यों और क्षेत्रों के लिए विकास प्रक्रिया को सूक्ष्मता से नियंत्रित करने की सुविधा देता है।

🌐 वेब इंटरफ़ेस

बिल्ट-इन वेब इंटरफ़ेस से अपने विकास परिणामों को मान्य करें:

cd web_interface
pip install -r requirements.txt
python app.py
http://localhost:5000 खोलें और एक्सेस करें:

```

--- Tranlated By Open Ai Tx | Last indexed: 2025-07-18 ---