{"id":24672520,"url":"https://github.com/cashewpillar/inquizitor","last_synced_at":"2025-10-08T07:30:56.949Z","repository":{"id":37984956,"uuid":"451938182","full_name":"cashewpillar/inquizitor","owner":"cashewpillar","description":"REST API for managing/ administering quizzes. Built with FastAPI, refresh tokens, tests utilizing factories, and equipped with machine learning to aid in cheating detection","archived":false,"fork":false,"pushed_at":"2023-03-12T03:16:53.000Z","size":13328,"stargazers_count":6,"open_issues_count":1,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2023-07-16T18:27:05.037Z","etag":null,"topics":["docker","docker-compose","factory-boy","fastapi","github-actions","json-schema","jwt","login","machine-learning","postgresql","pytest","python","python3","quiz","rest-api","sqlite","swagger"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cashewpillar.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-01-25T15:43:40.000Z","updated_at":"2023-07-16T18:27:05.037Z","dependencies_parsed_at":"2023-01-25T13:16:08.530Z","dependency_job_id":null,"html_url":"https://github.com/cashewpillar/inquizitor","commit_stats":null,"previous_names":[],"tags_count":0,"template":null,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cashewpillar%2Finquizitor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cashewpillar%2Finquizitor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cashewpillar%2Finquizitor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cashewpillar%2Finquizitor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cashewpillar","download_url":"https://codeload.github.com/cashewpillar/inquizitor/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":235688601,"owners_count":19029915,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","docker-compose","factory-boy","fastapi","github-actions","json-schema","jwt","login","machine-learning","postgresql","pytest","python","python3","quiz","rest-api","sqlite","swagger"],"created_at":"2025-01-26T10:14:01.140Z","updated_at":"2025-10-08T07:30:51.337Z","avatar_url":"https://github.com/cashewpillar.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Setup\n\n0. Install poetry: `pip install poetry`, then clone the repository\n1. Change directory to the cloned repository \n2. Make a copy of the file `.env.example`, rename it to `.env`, and set environment variables. Or don't change content of file to use default values for development. See `.env.example` file for reference\n3. Activate virtual environment using the command `poetry shell`\n   - Make sure the virtual environment is activated before running the next commands within the project folder\n4. Install project dependencies: `poetry install`\n5. Initialize database: `python main.py initial-data`\n   - If there is an error when generating using realistic data, simply retry the command. Should the error persist, please open an issue. \n6. Run the app: `uvicorn main:app --reload`\n\n\u003cbr\u003e\n\n## Dev\n\n| Username         | Password     |\n| ---------------- | ------------ |\n| admin            | superadmin   |\n| teacher          | superteacher |\n| \\\u003cdummy-teacher\u003e | testteacher  |\n| student          | superstudent |\n| \\\u003cdummy-student\u003e | teststudent  |\n\n- Reset database: `python main.py initial-data`\n- Run tests: `pytest`\n- Create an account: `python main.py create-account [OPTIONS] EMAIL LAST_NAME FIRST_NAME`\n    - where `[OPTIONS]` include username, password, is-student, is-teacher, is-admin\n    - example: `python main.py create-account --is-teacher=True test@tests.com jose rizal` \n- Create accounts from CSV file: `python main.py create-accounts FILEPATH`\n   - example: `python main.py create-accounts inquizitor\\data\\accounts.csv`\n- Use [Black Playground](https://black.vercel.app/) to check if code snippet conforms to PEP8\n- View SQLite database using [sqlitebrowser](https://sqlitebrowser.org/dl/) , otherwise use pgadmin\n  - if using SQLite, run the installed sqlitebrowser\n  - on the main white space upon running the app, drag\u0026drop the `data.db` file (found within app module after running initial-data)  \n  - under the Tables(n) tab, right-click the table you want to view and select 'Browse'\n\n \u003cbr\u003e\n\n## Docker Setup\n\nIf you want to use Docker, it is recommended to have a free diskspace of 2 GB. Running docker-compose will eventually download 1.2 GB at the minimum.  \n\n0. Install Docker: [Ubuntu Linux](https://www.digitalocean.com/community/tutorials/how-to-install-and-use-docker-on-ubuntu-18-04) - [Windows](https://docs.docker.com/docker-for-windows/install/)\n1. Change directory to the cloned repository\n2. Make a copy of the file `.env.example`, rename it to `.env`, and set environment variables. Or don't change content of file to use default values for development. See `.env.example` file for reference\n3. Run the entire app (backend and db): `docker-compose up -d`\n   - Remove `-d` to enable the logs\n4. Initialize/ reset the database: `docker exec inquizitor_backend_1 python main.py initial-data`\n\n\u003cbr\u003e\n\n## Integrations\n\n| Usage                                                       | App                                                          | Creator                                               |\n| ----------------------------------------------------------- | ------------------------------------------------------------ | ----------------------------------------------------- |\n| Realistic Quiz Data (`inquizitor\\inquizitor\\db\\init_db.py`) | [Open Trivia DB](https://opentdb.com/)                       | [PIXELTAIL GAMES LLC](http://www.pixeltailgames.com/) |\n| Frontend                                                    | [Inquizitor Frontend](https://github.com/xtian18/inquizitor-front-end) | [xtian18](https://github.com/xtian18)                 |\n| Cheating Detection                                          | [Cheating Detection Model](https://github.com/Iionsroar/inquizitor/blob/main/thesis_model.pkl) | [ralf-t](https://github.com/ralf-t)                   |\n\n\u003cbr\u003e\n\n## Docker Commands\n\n1. If you made changes to the `Dockerfile`, rebuild the image for the service backend: `docker-compose up --build`\n2. If you made changes to the `docker-compose.yml` file, re-run the app: `docker-compose up`\n3. If you made changes to the backend code, restart the backend container: `docker-compose restart backend`\n4. Run backend tests using: `docker exec inquizitor_backend_1 pytest`\n\n\u003cbr\u003e\n\n## Documentation\n\nto access the interactive API documentation, go to http://127.0.0.1:8000/docs\n\n\u003cimg src=\"media/doc-swagger-ui.png\" style=\"zoom: 200%;\" /\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcashewpillar%2Finquizitor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcashewpillar%2Finquizitor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcashewpillar%2Finquizitor/lists"}