Rename the data_sources module to content

This commit is contained in:
sabaimran 2023-11-21 22:11:32 -08:00
parent 4cb28aeffb
commit 1e2af083f0
23 changed files with 20 additions and 20 deletions

View file

@ -9,8 +9,8 @@ import requests
from khoj.database.models import Entry as DbEntry from khoj.database.models import Entry as DbEntry
from khoj.database.models import GithubConfig, KhojUser from khoj.database.models import GithubConfig, KhojUser
from khoj.processor.data_sources.markdown.markdown_to_entries import MarkdownToEntries from khoj.processor.content.markdown.markdown_to_entries import MarkdownToEntries
from khoj.processor.data_sources.org_mode.org_to_entries import OrgToEntries from khoj.processor.content.org_mode.org_to_entries import OrgToEntries
from khoj.processor.text_to_entries import TextToEntries from khoj.processor.text_to_entries import TextToEntries
# Internal Packages # Internal Packages

View file

@ -7,7 +7,7 @@ from khoj.database.models import Entry as DbEntry
from khoj.database.models import KhojUser from khoj.database.models import KhojUser
# Internal Packages # Internal Packages
from khoj.processor.data_sources.org_mode import orgnode from khoj.processor.content.org_mode import orgnode
from khoj.processor.text_to_entries import TextToEntries from khoj.processor.text_to_entries import TextToEntries
from khoj.utils import state from khoj.utils import state
from khoj.utils.helpers import timer from khoj.utils.helpers import timer

View file

@ -7,12 +7,12 @@ from pydantic import BaseModel
from starlette.authentication import requires from starlette.authentication import requires
from khoj.database.models import GithubConfig, KhojUser, NotionConfig from khoj.database.models import GithubConfig, KhojUser, NotionConfig
from khoj.processor.data_sources.github.github_to_entries import GithubToEntries from khoj.processor.content.github.github_to_entries import GithubToEntries
from khoj.processor.data_sources.markdown.markdown_to_entries import MarkdownToEntries from khoj.processor.content.markdown.markdown_to_entries import MarkdownToEntries
from khoj.processor.data_sources.notion.notion_to_entries import NotionToEntries from khoj.processor.content.notion.notion_to_entries import NotionToEntries
from khoj.processor.data_sources.org_mode.org_to_entries import OrgToEntries from khoj.processor.content.org_mode.org_to_entries import OrgToEntries
from khoj.processor.data_sources.pdf.pdf_to_entries import PdfToEntries from khoj.processor.content.pdf.pdf_to_entries import PdfToEntries
from khoj.processor.data_sources.plaintext.plaintext_to_entries import PlaintextToEntries from khoj.processor.content.plaintext.plaintext_to_entries import PlaintextToEntries
from khoj.routers.helpers import update_telemetry_state from khoj.routers.helpers import update_telemetry_state
from khoj.search_type import image_search, text_search from khoj.search_type import image_search, text_search
from khoj.utils import constants, state from khoj.utils import constants, state

View file

@ -18,8 +18,8 @@ from khoj.database.models import (
LocalOrgConfig, LocalOrgConfig,
LocalPlaintextConfig, LocalPlaintextConfig,
) )
from khoj.processor.data_sources.org_mode.org_to_entries import OrgToEntries from khoj.processor.content.org_mode.org_to_entries import OrgToEntries
from khoj.processor.data_sources.plaintext.plaintext_to_entries import PlaintextToEntries from khoj.processor.content.plaintext.plaintext_to_entries import PlaintextToEntries
from khoj.processor.embeddings import CrossEncoderModel, EmbeddingsModel from khoj.processor.embeddings import CrossEncoderModel, EmbeddingsModel
from khoj.routers.indexer import configure_content from khoj.routers.indexer import configure_content
from khoj.search_type import image_search, text_search from khoj.search_type import image_search, text_search

View file

@ -13,7 +13,7 @@ from PIL import Image
from khoj.configure import configure_routes, configure_search_types from khoj.configure import configure_routes, configure_search_types
from khoj.database.adapters import EntryAdapters from khoj.database.adapters import EntryAdapters
from khoj.database.models import KhojApiUser, KhojUser from khoj.database.models import KhojApiUser, KhojUser
from khoj.processor.data_sources.org_mode.org_to_entries import OrgToEntries from khoj.processor.content.org_mode.org_to_entries import OrgToEntries
from khoj.search_type import image_search, text_search from khoj.search_type import image_search, text_search
from khoj.utils import state from khoj.utils import state
from khoj.utils.rawconfig import ContentConfig, SearchConfig from khoj.utils.rawconfig import ContentConfig, SearchConfig

View file

@ -4,7 +4,7 @@ from pathlib import Path
import os import os
# Internal Packages # Internal Packages
from khoj.processor.data_sources.markdown.markdown_to_entries import MarkdownToEntries from khoj.processor.content.markdown.markdown_to_entries import MarkdownToEntries
from khoj.utils.fs_syncer import get_markdown_files from khoj.utils.fs_syncer import get_markdown_files
from khoj.utils.rawconfig import TextContentConfig from khoj.utils.rawconfig import TextContentConfig

View file

@ -5,7 +5,7 @@ from urllib.parse import quote
import pytest import pytest
from khoj.database.models import KhojApiUser, KhojUser from khoj.database.models import KhojApiUser, KhojUser
from khoj.processor.data_sources.org_mode.org_to_entries import OrgToEntries from khoj.processor.content.org_mode.org_to_entries import OrgToEntries
# Internal Packages # Internal Packages
from khoj.search_type import text_search from khoj.search_type import text_search

View file

@ -3,7 +3,7 @@ import json
import os import os
# Internal Packages # Internal Packages
from khoj.processor.data_sources.org_mode.org_to_entries import OrgToEntries from khoj.processor.content.org_mode.org_to_entries import OrgToEntries
from khoj.processor.text_to_entries import TextToEntries from khoj.processor.text_to_entries import TextToEntries
from khoj.utils.helpers import is_none_or_empty from khoj.utils.helpers import is_none_or_empty
from khoj.utils.rawconfig import Entry from khoj.utils.rawconfig import Entry

View file

@ -2,7 +2,7 @@
import datetime import datetime
# Internal Packages # Internal Packages
from khoj.processor.data_sources.org_mode import orgnode from khoj.processor.content.org_mode import orgnode
# Test # Test

View file

@ -3,7 +3,7 @@ import json
import os import os
# Internal Packages # Internal Packages
from khoj.processor.data_sources.pdf.pdf_to_entries import PdfToEntries from khoj.processor.content.pdf.pdf_to_entries import PdfToEntries
from khoj.utils.fs_syncer import get_pdf_files from khoj.utils.fs_syncer import get_pdf_files
from khoj.utils.rawconfig import TextContentConfig from khoj.utils.rawconfig import TextContentConfig

View file

@ -4,7 +4,7 @@ import os
from pathlib import Path from pathlib import Path
from khoj.database.models import KhojUser, LocalPlaintextConfig from khoj.database.models import KhojUser, LocalPlaintextConfig
from khoj.processor.data_sources.plaintext.plaintext_to_entries import PlaintextToEntries from khoj.processor.content.plaintext.plaintext_to_entries import PlaintextToEntries
# Internal Packages # Internal Packages
from khoj.utils.fs_syncer import get_plaintext_files from khoj.utils.fs_syncer import get_plaintext_files

View file

@ -8,8 +8,8 @@ from pathlib import Path
import pytest import pytest
from khoj.database.models import Entry, GithubConfig, KhojUser, LocalOrgConfig from khoj.database.models import Entry, GithubConfig, KhojUser, LocalOrgConfig
from khoj.processor.data_sources.github.github_to_entries import GithubToEntries from khoj.processor.content.github.github_to_entries import GithubToEntries
from khoj.processor.data_sources.org_mode.org_to_entries import OrgToEntries from khoj.processor.content.org_mode.org_to_entries import OrgToEntries
# Internal Packages # Internal Packages
from khoj.search_type import text_search from khoj.search_type import text_search