Skip to content

Commit b8da48e

Browse files
committed
Ruff fixes
1 parent 37f8c04 commit b8da48e

File tree

5 files changed

+1
-6
lines changed

5 files changed

+1
-6
lines changed

dspy/adapters/chat_adapter.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
from pydantic import TypeAdapter
1616
from collections.abc import Mapping
1717
from pydantic.fields import FieldInfo
18-
from typing import Dict, KeysView, List, Literal, NamedTuple, get_args, get_origin
18+
from typing import Dict, List, Literal, NamedTuple, get_args, get_origin
1919

2020
from dspy.adapters.base import Adapter
2121
from ..signatures.field import OutputField

dspy/adapters/image_utils.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ def from_file(cls, file_path: str):
4141

4242
@classmethod
4343
def from_PIL(cls, pil_image):
44-
import PIL
4544
return cls(url=encode_image(pil_image))
4645

4746
@model_serializer()

dspy/predict/predict.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@
1010
from dspy.primitives.program import Module
1111
from dspy.signatures.signature import ensure_signature, signature_to_template
1212
from dspy.utils.callback import with_callbacks
13-
from dspy.adapters.image_utils import Image
1413

1514
@lru_cache(maxsize=None)
1615
def warn_once(msg: str):

examples/vlm/mmlongbench-doc.ipynb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,6 @@
1919
"import dspy\n",
2020
"from dspy.datasets import DataLoader\n",
2121
"from dspy.evaluate.metrics import answer_exact_match\n",
22-
"from typing import List\n",
23-
"from dspy.evaluate import Evaluate\n",
2422
"\n",
2523
"import dotenv\n",
2624
"import litellm\n",

examples/vlm/mmmu.ipynb

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1032,7 +1032,6 @@
10321032
],
10331033
"source": [
10341034
"import dspy\n",
1035-
"from dspy import Module, Predict\n",
10361035
"from typing import List\n",
10371036
"class ColorSignature(dspy.Signature):\n",
10381037
" \"\"\"Output the color of the designated image.\"\"\"\n",

0 commit comments

Comments
 (0)