Skip to content

Commit

Permalink
Merge pull request #36 from studio-recoding/feat/cicd
Browse files Browse the repository at this point in the history
[refactor] metadata 추가
  • Loading branch information
uommou authored Mar 24, 2024
2 parents 842fc01 + 2c6d620 commit 69396f9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/database/chroma_db.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ async def add_db_data(schedule_data: AddScheduleDTO):
schedules.add(
documents=[schedule_data.data],
ids=[str(schedule_data.schedule_id)],
metadatas=[{"datetime": schedule_data.schedule_datetime, "member": schedule_data.member_id, "category": schedule_data.category, "location": schedule_data.location, "person": schedule_data.person}]
metadatas=[{"datetime_start": schedule_data.schedule_datetime_start, "datetime_end": schedule_data.schedule_datetime_end, "member": schedule_data.member_id, "category": schedule_data.category, "location": schedule_data.location, "person": schedule_data.person}]
)
return True

Expand Down
3 changes: 2 additions & 1 deletion app/dto/db_dto.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@

class AddScheduleDTO(BaseModel):
data: str
schedule_datetime: str # datetime.datetime 타입을 명시적으로 사용합니다.
schedule_datetime_start: str # datetime.datetime 타입을 명시적으로 사용합니다.
schedule_datetime_end: str
schedule_id: int
member_id: int
category: str
Expand Down

0 comments on commit 69396f9

Please sign in to comment.