diff --git a/scrapontology/extractor.py b/scrapontology/extractor.py index 3a545a0..02e9305 100644 --- a/scrapontology/extractor.py +++ b/scrapontology/extractor.py @@ -1,17 +1,15 @@ import logging from abc import ABC, abstractmethod -from typing import List, Tuple, Dict, Any, Optional +from typing import List, Dict, Any, Optional from .primitives import Entity, Relation from .parsers.base_parser import BaseParser -from .parsers.prompts import DELETE_PROMPT, UPDATE_ENTITIES_PROMPT, UPDATE_SCHEMA_PROMPT, CREATE_TABLES_PROMPT -from .llm_client import LLMClient +from .parsers.prompts import DELETE_PROMPT, UPDATE_SCHEMA_PROMPT, CREATE_TABLES_PROMPT from .parsers.prompts import UPDATE_SCHEMA_PROMPT from .db_client import DBClient, PostgresDBClient import json from langgraph.graph import StateGraph, END, START -from typing import TypedDict, Literal +from typing import Literal from scrapontology.db_client import PostgresDBClient -from scrapontology.llm_client import LLMClient from pydantic import BaseModel logger = logging.getLogger(__name__) logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s') diff --git a/scrapontology/llm_client.py b/scrapontology/llm_client.py index 1e45f58..c104bd8 100644 --- a/scrapontology/llm_client.py +++ b/scrapontology/llm_client.py @@ -1,8 +1,6 @@ import requests import logging -from typing import Dict, Any, Optional, List -from typing import Any, Callable -from pydantic_core import CoreSchema, core_schema +from typing import Dict, Optional logger = logging.getLogger(__name__) diff --git a/scrapontology/parsers/pdf_parser.py b/scrapontology/parsers/pdf_parser.py index f8cf9ae..ba1e0ef 100644 --- a/scrapontology/parsers/pdf_parser.py +++ b/scrapontology/parsers/pdf_parser.py @@ -16,7 +16,6 @@ from langgraph.graph import StateGraph, START, END from pydantic import BaseModel from typing import Optional, List -from collections import defaultdict # Set up logging