Skip to content

Commit

Permalink
Fixing complete
Browse files Browse the repository at this point in the history
  • Loading branch information
seanchatmangpt committed Feb 19, 2024
1 parent 77cfe69 commit 683dd7e
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/experiments/complete.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@

from utils.models import get_model

client = AsyncOpenAI()


@dataclass
Expand Down Expand Up @@ -188,6 +187,8 @@ async def acreate(*, config: Optional[LLMConfig] = None, **kwargs):
)

else:
client = AsyncOpenAI()

response = await client.completions.create(
model=model,
prompt=prompt,
Expand Down Expand Up @@ -525,6 +526,8 @@ def _create_messages(sys_msg, prompt, msgs):


async def main():
client = AsyncOpenAI()

await acreate(
prompt="Convert the CLI to Typer and use jinja withing the echo",
model="chatgpt",
Expand Down

0 comments on commit 683dd7e

Please sign in to comment.