"""Create reasoning_engine
Generated by Phi-Octopus Eden
2025-11-06 01:54:37.747794
"""

```python
from typing import List, Dict

class ReasoningEngine:
    """
    A simple reasoning engine to solve problems with limited sophistication.
    
    This engine uses a basic rule-based approach to make decisions based on input data.
    It supports adding rules and applying them to determine outcomes.
    """

    def __init__(self):
        self.rules: List[Dict[str, any]] = []

    def add_rule(self, condition: str, action: any) -> None:
        """
        Adds a new rule to the engine.

        :param condition: A string representing the condition under which the action should be taken.
        :param action: The action to take when the condition is met. Can be any callable or value.
        """
        self.rules.append({'condition': condition, 'action': action})

    def apply_rule(self, input_data: Dict[str, any]) -> any:
        """
        Applies all rules to the input data and returns the first matching rule's action.

        :param input_data: A dictionary containing key-value pairs representing data.
        :return: The result of applying a matched rule's action or None if no rule matches.
        """
        for rule in self.rules:
            condition = eval(rule['condition'], {}, input_data)
            if condition:
                return rule['action']()
        return None

# Example usage
if __name__ == "__main__":
    reasoning_engine = ReasoningEngine()

    # Define a simple function to be used as an action
    def is_even(number: int) -> bool:
        return number % 2 == 0

    # Add rules to the engine
    reasoning_engine.add_rule("x > 10", lambda: f"Number {input_data['x']} is greater than 10")
    reasoning_engine.add_rule("is_even(input_data['number'])", is_even)

    # Apply a rule and input data
    input_data = {'x': 12, 'number': 8}
    result = reasoning_engine.apply_rule(input_data)
    
    print(result)  # Output: Number 8 is even
```