Skip to content

Commit

Permalink
fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
epinzur committed Aug 12, 2024
1 parent 51f0502 commit 5f87321
Show file tree
Hide file tree
Showing 7 changed files with 13 additions and 25 deletions.
7 changes: 2 additions & 5 deletions libs/ragulate/ragstack_ragulate/cli_commands/compare.py
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
from __future__ import annotations

from typing import TYPE_CHECKING, Any
from typing import Any

from ragstack_ragulate.analysis import Analysis

from .utils import remove_sqlite_extension

if TYPE_CHECKING:
from argparse import ArgumentParser, _SubParsersAction


def setup_compare(subparsers: _SubParsersAction[ArgumentParser]) -> None:
def setup_compare(subparsers) -> None:
"""Setup the compare command."""
compare_parser = subparsers.add_parser(
"compare", help="Compare results from 2 (or more) recipes"
Expand Down
3 changes: 1 addition & 2 deletions libs/ragulate/ragstack_ragulate/cli_commands/dashboard.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
from argparse import ArgumentParser, _SubParsersAction
from typing import Any

from ragstack_ragulate.dashboard import run_dashboard

from .utils import remove_sqlite_extension


def setup_dashboard(subparsers: _SubParsersAction[ArgumentParser]) -> None:
def setup_dashboard(subparsers) -> None:
"""Setup the dashboard command."""
dashboard_parser = subparsers.add_parser(
"dashboard",
Expand Down
3 changes: 1 addition & 2 deletions libs/ragulate/ragstack_ragulate/cli_commands/download.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
from argparse import ArgumentParser, _SubParsersAction
from typing import Any

from ragstack_ragulate.datasets import get_dataset


def setup_download(subparsers: _SubParsersAction[ArgumentParser]) -> None:
def setup_download(subparsers) -> None:
"""Setup the download command."""
download_parser = subparsers.add_parser("download", help="Download a dataset")
download_parser.add_argument(
Expand Down
7 changes: 2 additions & 5 deletions libs/ragulate/ragstack_ragulate/cli_commands/ingest.py
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
from __future__ import annotations

from typing import TYPE_CHECKING, Any
from typing import Any

from ragstack_ragulate.datasets import find_dataset
from ragstack_ragulate.pipelines import IngestPipeline
from ragstack_ragulate.utils import convert_vars_to_ingredients

if TYPE_CHECKING:
from argparse import ArgumentParser, _SubParsersAction


def setup_ingest(subparsers: _SubParsersAction[ArgumentParser]) -> None:
def setup_ingest(subparsers) -> None:
"""Setup the ingest command."""
ingest_parser = subparsers.add_parser("ingest", help="Run an ingest pipeline")
ingest_parser.add_argument(
Expand Down
7 changes: 2 additions & 5 deletions libs/ragulate/ragstack_ragulate/cli_commands/query.py
Original file line number Diff line number Diff line change
@@ -1,16 +1,13 @@
from __future__ import annotations

from typing import TYPE_CHECKING, Any
from typing import Any

from ragstack_ragulate.datasets import find_dataset
from ragstack_ragulate.pipelines import QueryPipeline
from ragstack_ragulate.utils import convert_vars_to_ingredients

if TYPE_CHECKING:
from argparse import ArgumentParser, _SubParsersAction


def setup_query(subparsers: _SubParsersAction[ArgumentParser]) -> None:
def setup_query(subparsers) -> None:
"""Setup the query command."""
query_parser = subparsers.add_parser("query", help="Run a query pipeline")
query_parser.add_argument(
Expand Down
7 changes: 2 additions & 5 deletions libs/ragulate/ragstack_ragulate/cli_commands/run.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,14 @@
from __future__ import annotations

from typing import TYPE_CHECKING, Any
from typing import Any

from ragstack_ragulate.analysis import Analysis
from ragstack_ragulate.config import ConfigParser
from ragstack_ragulate.logging_config import logger
from ragstack_ragulate.pipelines import IngestPipeline, QueryPipeline

if TYPE_CHECKING:
from argparse import ArgumentParser, _SubParsersAction


def setup_run(subparsers: _SubParsersAction[ArgumentParser]) -> None:
def setup_run(subparsers) -> None:
"""Setup the run command."""
run_parser = subparsers.add_parser(
"run", help="Run an experiment from a config file"
Expand Down
4 changes: 3 additions & 1 deletion libs/ragulate/ragstack_ragulate/pipelines/query_pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

from tqdm import tqdm
from trulens_eval import Tru, TruChain
from trulens_eval.feedback.provider import AzureOpenAI, Huggingface, LLMProvider, OpenAI
from trulens_eval.feedback.provider import AzureOpenAI, Huggingface, OpenAI
from trulens_eval.schema.feedback import FeedbackMode, FeedbackResultStatus
from typing_extensions import Never, override

Expand All @@ -19,6 +19,8 @@
from .feedbacks import Feedbacks

if TYPE_CHECKING:
from trulens_eval.feedback.provider.base import LLMProvider

from ragstack_ragulate.datasets import BaseDataset, QueryItem


Expand Down

0 comments on commit 5f87321

Please sign in to comment.