From 6b85f377feaded29bf58ddcc79cb10c70f1975ec Mon Sep 17 00:00:00 2001 From: Hemanth Sai Garladinne <73033596+HemanthSai7@users.noreply.github.com> Date: Sat, 30 Sep 2023 14:12:01 +0530 Subject: [PATCH 1/6] Update Code.py --- frontend/pages/Code.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/frontend/pages/Code.py b/frontend/pages/Code.py index 8d5a9d9..c7d5b87 100644 --- a/frontend/pages/Code.py +++ b/frontend/pages/Code.py @@ -52,7 +52,7 @@ def instructions(): if st.button("Generate API KEY"): with st.spinner("Generating API Key..."): try: - base_url = "http://localhost:8000" + base_url = "https://caffeinecrew-techdocs.hf.space" headers={"accept":"application/json", "Authorization": f"Bearer {st.session_state.access_token}"} response = requests.put(url=base_url + "/auth/regenerate_api_key", headers=headers, data=json.dumps({"username":st.session_state.username})) if (response.status_code!=200): @@ -73,7 +73,7 @@ def instructions(): def code_page(): - base_url = 'http://localhost:8000' + base_url = 'https://caffeinecrew-techdocs.hf.space' def query_post(url, headers, data=None, params=None): response = requests.post(url, data=data, headers=headers, params=params) @@ -107,4 +107,4 @@ def query_post(url, headers, data=None, params=None): st.session_state.runpage = auth_page else: st.session_state.runpage = code_page -st.session_state.runpage() \ No newline at end of file +st.session_state.runpage() From 07056bca133a2af14135697739972fa6665fe495 Mon Sep 17 00:00:00 2001 From: Hemanth Sai Garladinne <73033596+HemanthSai7@users.noreply.github.com> Date: Sat, 30 Sep 2023 14:12:13 +0530 Subject: [PATCH 2/6] Update Login.py --- frontend/Login.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/Login.py b/frontend/Login.py index a31d5ce..6648c82 100644 --- a/frontend/Login.py +++ b/frontend/Login.py @@ -6,7 +6,7 @@ def auth_page(): - base_url = 'http://localhost:8000' + base_url = 'https://caffeinecrew-techdocs.hf.space' headers={"accept":"application/json"} From e61d568075636e87104b7339474c70cf85042226 Mon Sep 17 00:00:00 2001 From: Mayuresh Agashe <75118658+mayureshagashe2105@users.noreply.github.com> Date: Sat, 30 Sep 2023 14:22:10 +0530 Subject: [PATCH 3/6] Update router.py --- TechdocsAPI/backend/router.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/TechdocsAPI/backend/router.py b/TechdocsAPI/backend/router.py index 222f0b0..de59398 100644 --- a/TechdocsAPI/backend/router.py +++ b/TechdocsAPI/backend/router.py @@ -15,6 +15,11 @@ allow_headers=["*"], ) + +@app.get("/", tags=["Home"]) +def api_home(): + return {'detail': 'Welcome to Techdocs API'} + @app.get("/api/response_check", tags=["Resource Server"]) def api_response_check(): print("api_response_check") From b6df88e253969e525d19c1f77e3e1fc4b8646b16 Mon Sep 17 00:00:00 2001 From: Mayuresh Agashe <75118658+mayureshagashe2105@users.noreply.github.com> Date: Sat, 30 Sep 2023 14:37:32 +0530 Subject: [PATCH 4/6] Create .gitattributes --- .gitattributes | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .gitattributes diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..b3b1220 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,27 @@ +*.7z filter=lfs diff=lfs merge=lfs -text +*.arrow filter=lfs diff=lfs merge=lfs -text +*.bin filter=lfs diff=lfs merge=lfs -text +*.bin.* filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.ftz filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.h5 filter=lfs diff=lfs merge=lfs -text +*.joblib filter=lfs diff=lfs merge=lfs -text +*.lfs.* filter=lfs diff=lfs merge=lfs -text +*.model filter=lfs diff=lfs merge=lfs -text +*.msgpack filter=lfs diff=lfs +*.onnx filter=lfs diff=lfs merge=lfs -text +*.ot filter=lfs diff=lfs merge=lfs -text +*.parquet filter=lfs diff=lfs merge=lfs -text +*.pb filter=lfs diff=lfs merge=lfs -text +*.pt filter=lfs diff=lfs merge=lfs -text +*.pth filter=lfs diff=lfs merge=lfs -text +*.rar filter=lfs diff=lfs merge=lfs -text +saved_model/**/* filter=lfs diff=lfs merge=lfs -text +*.tar.* filter=lfs diff=lfs merge=lfs -text +*.tflite filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs dif +*.zip filter=lfs diff=lfs merge=lfs -text +*.zstandard filter=lfs diff=lfs merge=lfs -text +*tfevents* filter=lfs diff=lfs merge=lfs -text From ffb87a1ac0e351cd3fb6423de5a3e35c33ad5bb9 Mon Sep 17 00:00:00 2001 From: Mayuresh Agashe <75118658+mayureshagashe2105@users.noreply.github.com> Date: Sat, 30 Sep 2023 14:39:26 +0530 Subject: [PATCH 5/6] Update .gitattributes --- .gitattributes | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitattributes b/.gitattributes index b3b1220..f1062a0 100644 --- a/.gitattributes +++ b/.gitattributes @@ -25,3 +25,5 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text *.zip filter=lfs diff=lfs merge=lfs -text *.zstandard filter=lfs diff=lfs merge=lfs -text *tfevents* filter=lfs diff=lfs merge=lfs -text +*.jpg +*.png From 64c74eaa3c3ecb1e7b701cd4477d0dbf325851db Mon Sep 17 00:00:00 2001 From: Mayuresh Agashe <75118658+mayureshagashe2105@users.noreply.github.com> Date: Sat, 30 Sep 2023 14:41:09 +0530 Subject: [PATCH 6/6] Update .gitattributes --- .gitattributes | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitattributes b/.gitattributes index f1062a0..5dd1571 100644 --- a/.gitattributes +++ b/.gitattributes @@ -25,5 +25,5 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text *.zip filter=lfs diff=lfs merge=lfs -text *.zstandard filter=lfs diff=lfs merge=lfs -text *tfevents* filter=lfs diff=lfs merge=lfs -text -*.jpg -*.png +git lfs track *.jpg +git lfs track *.png