mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-10-04 12:07:34 +00:00
api build works for conda now
This commit is contained in:
parent
c4fe72c3a3
commit
2076d2b6db
5 changed files with 28 additions and 15 deletions
|
@ -71,7 +71,6 @@ def prompt_for_config(
|
|||
"""
|
||||
config_data = {}
|
||||
|
||||
print(f"Configuring {config_type.__name__}:")
|
||||
for field_name, field in config_type.__fields__.items():
|
||||
field_type = field.annotation
|
||||
|
||||
|
@ -86,7 +85,6 @@ def prompt_for_config(
|
|||
if not isinstance(field.default, PydanticUndefinedType)
|
||||
else None
|
||||
)
|
||||
print(f" {field_name}: {field_type} (default: {default_value})")
|
||||
is_required = field.is_required
|
||||
|
||||
# Skip fields with Literal type
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
# the root directory of this source tree.
|
||||
|
||||
import json
|
||||
from datetime import datetime
|
||||
from enum import Enum
|
||||
|
||||
|
||||
|
@ -12,4 +13,6 @@ class EnumEncoder(json.JSONEncoder):
|
|||
def default(self, obj):
|
||||
if isinstance(obj, Enum):
|
||||
return obj.value
|
||||
elif isinstance(obj, datetime):
|
||||
return obj.isoformat()
|
||||
return super().default(obj)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue