mirror of
https://github.com/kennethreitz/instructor.git
synced 2026-06-05 22:50:18 +00:00
docs: Missing Import + Wrong Variable Name (#507)
This commit is contained in:
@@ -13,7 +13,7 @@ The `Search` class is a Pydantic model that defines the structure of the search
|
||||
```python
|
||||
import instructor
|
||||
from openai import OpenAI
|
||||
from typing import Iterable
|
||||
from typing import Iterable, Literal
|
||||
from pydantic import BaseModel, Field
|
||||
|
||||
# Apply the patch to the OpenAI client
|
||||
@@ -30,7 +30,7 @@ class Search(BaseModel):
|
||||
)
|
||||
|
||||
|
||||
def segment(data: str) -> MultiSearch:
|
||||
def segment(data: str) -> Search:
|
||||
return client.chat.completions.create(
|
||||
model="gpt-3.5-turbo-0613",
|
||||
response_model=Iterable[Search],
|
||||
|
||||
Reference in New Issue
Block a user