"""Create fact_checker
Generated by Phi-Octopus Eden
2025-11-06 04:49:38.069733
"""

```python
from typing import List, Dict


class FactChecker:
    """
    A simple fact-checking system capable of evaluating statements based on provided facts.
    
    Args:
        knowledge_base: A dictionary where keys are topics and values are lists of related facts.
    """

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

    def check_fact(self, topic: str, fact: str) -> bool:
        """
        Check if the given fact is present in the knowledge base for a specific topic.

        Args:
            topic: The topic to which the fact should belong.
            fact: The statement to be checked.

        Returns:
            True if the fact exists in the knowledge base for the specified topic, False otherwise.
        """
        return fact in self.knowledge_base.get(topic, [])

    def list_facts(self, topic: str) -> List[str]:
        """
        List all facts associated with a specific topic.

        Args:
            topic: The topic to retrieve facts from.

        Returns:
            A list of facts related to the given topic.
        """
        return self.knowledge_base.get(topic, [])

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

        Args:
            topic: The topic under which to store the new fact.
            fact: The statement to be added as a new fact.
        """
        if topic in self.knowledge_base:
            self.knowledge_base[topic].append(fact)
        else:
            self.knowledge_base[topic] = [fact]


# Example usage
if __name__ == "__main__":
    # Initialize knowledge base with some facts
    knowledge_base = {
        "politics": ["The President is the head of state", "Elections are held every 4 years"],
        "science": ["Water boils at 100 degrees Celsius", "DNA is a double helix"]
    }

    fact_checker = FactChecker(knowledge_base)

    # Check if facts exist in the knowledge base
    print(fact_checker.check_fact("politics", "The President is the head of state"))  # Output: True
    print(fact_checker.check_fact("science", "Space is filled with nothingness"))  # Output: False

    # List all facts for a specific topic
    print(fact_checker.list_facts("politics"))  # Output: ['The President is the head of state', 'Elections are held every 4 years']

    # Add a new fact to the knowledge base
    fact_checker.add_fact("science", "Photosynthesis occurs in plants")
    print(fact_checker.list_facts("science"))  # Output: ['Water boils at 100 degrees Celsius', 'DNA is a double helix', 'Photosynthesis occurs in plants']
```