Giter Club home page Giter Club logo

nutriai-api's Introduction

NutriAI_logo

Nutri-AI

이미지 분석을 통한 식단 분석 및 영양제 추천 서비스 구현

API

app_v3 - NutriAI 구현 서비스

FastAPI Docs

https://fastapi.tiangolo.com/

Folder Structure

app_v3/
│
├── main.py - FastAPI 인스턴스 생성 및 라우터 연결 모듈(실행 가능)
│
├── generate_table.py -  dynamo DB에 새로운 테이블을 생성하는 모듈
│
├── internal/ 
│       ├── database.py - dynamo DB와 S3 연동을 위해 접속 권한 키 작성 모듈
│
├── router/ 
│       ├── router.py - 클라이언트에게 Parameters 또는 Request Body에 어떠한 Input 데이터를 받을지 작성하는 모듈 
│
├── domain/ 
│       ├── domain.py - JSON 또는 Text 형태로 들어오는 Input 데이터를 받기 위해 Schema(for JSON)를 지정. 
│                       router에서 클라이언트에게 입력 받은 Input 데이터를 DB 접근 Key와 맞추거나, 
│                       DB에 추가될 value의 형태로 바꾸는 모듈
│
├── repository/ 
│       ├── repository.py - 실제 DB의 테이블에서 CRUD, Query 이용하여 작업을 수행하는 모듈
│       ├── tablename.py - DynamoDB 테이블 이름 작성
│

Requirements

Dockerfile

docker build -t 이미지이름:태그이름 .(경로)

docker run --rm -v $PWD:/workspace -p 8000:8000 -it 이미지이름:태그이름 bash

Transaction

  1. 신규 유저 가입
  2. 유저 정보 업데이트 - physique, RDI 수정
  3. 유저 physique 정보 요청
  4. 유저 정보 요청
  5. 유저 RDI 정보 요청
  6. 식단 이미지 S3 파일 서버에 업로드
  7. Inference 이미지 S3 파일 서버에서 가져오기
  8. 음식 영양 성분 요청
  9. 유저 식단 섭취 로그 등록
  10. 사용자 영양상태 로그 요청 - 특정 날짜 (식단 - 탄단지)
  11. 사용자 영양 상태 로그 요청 - 오늘부터 ndays일 (식단 + 영양제)
  12. today homepage 필요 정보 요청
  13. a week status 필요 정보 요청
  14. 유저 영양제 추천

Database

  • DynamoDB (AWS)
  • S3 (AWS)

nutriai-api's People

Contributors

kymjaehong avatar ziyoon avatar hyeniii avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.