Code Monkey home page Code Monkey logo

oclip-server's Introduction

oClip Media Server

Original Media Library REST API for using the oClip format.

Getting Started

  1. Install dependencies npm i

  2. Migrate database npx prisma migrate dev

  3. Run npm run dev

Routes

CRUD operations for

  • Video: Watch
  • File: source for videos
  • Segment: add tags to a portion of a video in respect to timestamps
  • Tag: Any data
  • TagType: Define what a tag is (e.g. author, transcript)

How content is handled

  1. All added content creates a new row in the Source table.
  2. Every source created automatically subsequently creates a new row in the Video table.
  3. Extensions can now process the video and return data generated in the form of segments {start,end,tags}

Project folder structure

  • /extensions: (implementation for ffmpeg, ml tools [reuse python wrapper], scheduler, child_process)
  • /middleware: universal route needs (e.g. auth, error, response delivery, req/res logging)
  • /prisma: database
  • /routes: (doubles as controllers) assign endpoints with services and pass to them data (no data logic)
  • /services: access data layer (no route logic)
  • /util: single purpose and reusable

Useful Commands

Prisma

# fix issues in prisma.schema
npx prisma format

# update database using migration files
npx prisma migrate dev

# prisma viewer (database editor gui)
npx prisma studio

oclip-server's People

Contributors

ariym avatar

Watchers

 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.