Add base project

This commit is contained in:
Tyler Perkins 2023-02-18 16:43:51 -05:00
parent 05d2e4b412
commit 6e47a764cd
5 changed files with 108 additions and 0 deletions

View File

@ -1,2 +1,3 @@
# AutoScheduler
This is an application that will automatically rearrange your calendar

62
requirements.txt Normal file
View File

@ -0,0 +1,62 @@
blis==0.7.9
catalogue==2.0.8
certifi==2022.12.7
charset-normalizer==3.0.1
click==8.1.3
confection==0.0.4
cymem==2.0.7
DateTime==4.9
en-core-web-md @ https://github.com/explosion/spacy-models/releases/download/en_core_web_md-3.5.0/en_core_web_md-3.5.0-py3-none-any.whl
filelock==3.9.0
Flask==2.2.2
httplib2==0.20.4
huggingface-hub==0.12.0
icalendar==4.0.9
icalevents==0.1.27
idna==3.4
itsdangerous==2.1.2
Jinja2==3.1.2
joblib==1.2.0
langcodes==3.3.0
MarkupSafe==2.1.2
murmurhash==1.0.9
nltk==3.8.1
numpy==1.24.2
nvidia-cublas-cu11==11.10.3.66
nvidia-cuda-nvrtc-cu11==11.7.99
nvidia-cuda-runtime-cu11==11.7.99
nvidia-cudnn-cu11==8.5.0.96
packaging==23.0
pathy==0.10.1
Pillow==9.4.0
preshed==3.0.8
pydantic==1.10.4
pyparsing==3.0.9
pysqlite3==0.5.0
python-dateutil==2.8.2
pytz==2021.3
PyYAML==6.0
regex==2022.10.31
requests==2.28.2
scikit-learn==1.2.1
scipy==1.10.0
sentencepiece==0.1.97
six==1.16.0
smart-open==6.3.0
spacy==3.5.0
spacy-legacy==3.0.12
spacy-loggers==1.0.4
srsly==2.4.5
thinc==8.1.7
threadpoolctl==3.1.0
tokenizers==0.13.2
torch==1.13.1
torchvision==0.14.1
tqdm==4.64.1
transformers==4.26.0
typer==0.7.0
typing_extensions==4.4.0
urllib3==1.26.14
wasabi==1.1.1
Werkzeug==2.2.2
zope.interface==5.5.2

10
src/api/__init__.py Normal file
View File

@ -0,0 +1,10 @@
from flask_restx import Api
from .users import api as usersNamespace
api = Api(
title='Auto Scheduler',
version=1.0,
description='A microservice to automatically schedule your calendar'
)
api.add_namespace(usersNamespace)

18
src/api/users.py Normal file
View File

@ -0,0 +1,18 @@
from flask_restx import Namespace, Resource, fields
api = Namespace('users', description='User management')
user = api.model('User', {
'name': fields.String(required=True,
description='The name of the user',
example="tyler"),
'token': fields.String(required=False,
description='auth token')
})
@api.route('/register')
class register(Resource):
@api.doc('register')
@api.marshal_with(user)
def post(self):
print(api.payload)

17
src/app.py Executable file
View File

@ -0,0 +1,17 @@
#!/usr/bin/python
# Entry point for flask
from flask import Flask
from api import api
import os
isDebug = False
#if os.environ["AUTOSCHEDULER_DEBUG"] == "True":
#isDebug = True
app = Flask(__name__)
api.init_app(app)
app.run(debug=isDebug)