helloeveryworlds/NoOn-Call

Reduce the on-call

★ 0Forks 0PythonGitHub ↗Compare

README

NoOn-Call

Reduce the on-call

Description

Reduce the on-call. When your boss call you when you are sleep or your team members ask some basic questions, it can help you accept the phone call or whatsApp call. You can upload your daily or knowledge on the local DB and it can answer the question based on the information you have put on the DB.

Knowledge capsule app

The project now includes a small web application that lets you collect unstructured knowledge items such as text, markdown, images, audio or video files. Every upload is stored on the local filesystem and indexed in a relational database together with:

  • The group it belongs to (e.g. Work, Learn).
  • A hierarchical folder path (e.g. Work/2024-04-30/Daily).
  • A set of tags (e.g. meeting-notes, design).
  • The storage location and the original text (when text or markdown is provided).

Features

  • Create and list groups and folders to mirror how you want to organise the knowledge base.
  • Upload plain text/markdown or attach files (images, documents, video, audio, etc.).
  • Automatically persists the binary assets to backend/storage/ while indexing metadata in a SQLite database (backend/data/knowledge.db).
  • Browse entries per group, preview captured text, open stored assets directly from the UI, and review applied tags.
  • Responsive, tech-themed interface optimised for desktop and tablet screens.

Project layout

backend/
  app/
    main.py          # FastAPI application
    database.py      # SQLAlchemy configuration and session helpers
    models.py        # ORM models for groups, folders, entries, tags
    schemas.py       # Pydantic request/response schemas
    storage.py       # Utilities for saving text/files to disk
  data/              # Created at runtime, stores the SQLite database
  storage/           # Created at runtime, stores uploaded assets
frontend/
  index.html         # Tech-styled UI
  styles.css         # Visual design tokens and layout
  app.js             # Frontend logic using the REST API
requirements.txt     # Backend dependencies

Running locally

  1. Install dependencies

    python -m venv .venv
    source .venv/bin/activate
    pip install -r requirements.txt
  2. Start the backend

    uvicorn backend.app.main:app --reload
  3. Open the UI

    Visit http://localhost:8000 to use the web application. All API endpoints are namespaced at the root (e.g. POST /groups, POST /entries) while the static assets are served from /ui and stored files from /storage.

Database engine

The backend uses SQLite for ease of local development and to satisfy the requirement of a locally hosted database. SQLAlchemy models can be migrated to MySQL or Postgres with minimal changes by updating the connection string in backend/app/database.py.

Contributors

Fuhao Ruan

Contributors

helloeveryworlds

Issues