Skip to content

Commit

Permalink
Merge pull request #523 from PrefectHQ/no-docstring
Browse files Browse the repository at this point in the history
  • Loading branch information
jlowin authored Aug 3, 2023
2 parents 32d7ed6 + 1ec814e commit 33ac87a
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/marvin/types/function.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,14 @@ def get_openai_function_schema(schema, model):

class FunctionConfig(BaseModel):
fn: Callable
name: Optional[str]
description: Optional[str]
name: str
description: str = ""
schema_extra: Optional[Callable] = get_openai_function_schema

def __init__(self, fn, **kwargs):
super().__init__(
fn=fn, **{"name": fn.__name__, "description": fn.__doc__, **kwargs}
)
kwargs.setdefault("name", fn.__name__ or "")
kwargs.setdefault("description", fn.__doc__ or "")
super().__init__(fn=fn, **kwargs)


class Function:
Expand Down

0 comments on commit 33ac87a

Please sign in to comment.