"""Create reasoning_engine
Generated by Phi-Octopus Eden
2025-11-06 23:38:06.759028
"""

```python
from typing import List, Tuple

class KnowledgeBase:
    def __init__(self):
        self.knowledge = []

    def add_fact(self, fact: str) -> None:
        """Add a fact to the knowledge base."""
        self.knowledge.append(fact)

    def query(self, question: str) -> bool:
        """Query the knowledge base with a question."""
        return any(question in fact for fact in self.knowledge)


class ReasoningEngine:
    """
    A basic reasoning engine that performs logical deductions based on facts.
    
    Example usage:
    >>> engine = ReasoningEngine()
    >>> engine.add_fact("All humans are mortal.")
    >>> engine.add_fact("Socrates is a human.")
    >>> engine.infer("Socrates is mortal.")  # Returns True
    """

    def __init__(self):
        self.kb = KnowledgeBase()

    def add_fact(self, fact: str) -> None:
        """Add a fact to the knowledge base."""
        self.kb.add_fact(fact)

    def infer(self, statement: str) -> bool:
        """
        Infer if a statement is logically entailed by the facts in the KB.
        
        :param statement: A logical statement to be inferred.
        :return: True if the statement can be inferred; otherwise False.
        """
        return self.kb.query(statement)

# Example usage
if __name__ == "__main__":
    engine = ReasoningEngine()
    engine.add_fact("All humans are mortal.")
    engine.add_fact("Socrates is a human.")
    
    print(engine.infer("Socrates is mortal."))  # Output: True

    engine.add_fact("Plato is not a human.")
    print(engine.infer("Plato is immortal."))   # Output: False
```

# Explanation of the code:
# - `KnowledgeBase` class manages facts and provides a query method to check if a fact or question is present.
# - `ReasoningEngine` uses the `KnowledgeBase` to add facts and infer statements based on those facts.
# - The example usage demonstrates adding facts about humans being mortal and how this affects inferences.