Skip to content

Commit

Permalink
Merge pull request #14 from sandbox-ai/LaLeyDeMilei_dev
Browse files Browse the repository at this point in the history
[FIX] Backend API endpoints
  • Loading branch information
tatakof authored Feb 9, 2024
2 parents e0c75cd + 8949f1a commit 1d550d1
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
24 changes: 24 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
## Main Branch
Prod branch is `main` and should be treated as such.
Dev branch is `LaLeyDeMilei_dev`. Every feature bust be a separate branch, originating from `LaLeyDeMilei_dev`.
Once a feature is ready, it can be merged to `LaLeyDeMilei_dev`, and if all is ok, then it will be merged to `main`.

## Branch names
- *WIP/featurename* - For Work In Progress, stuff that will not end soon
- *FEAT/featurename* - For feature that will be added or expanded
- *BUG/bugname* - For Bug
- *JUNK/junkname* - For experimental actions
- *ISSUE/issuenumber* - Obvious
- *REF/refname* - For violent refactoring
- *IMP/improvename* - For improvements
- *MISC/miscname* - For anything else (don't abuse)

## Commits names
- *[ADD] message* - For add
- *[MOD] message* - For modify
- *[REM] message* - For remove
- *[REF] message* - For moderate refactoring
- *[HOT] message* - For hot fix in master
- *[FIX] message* - For fix, but it is not HOT and it's throught another branch, not master
- *[MRG] message* - For Merge
- *[DOC] message* - For documentation
2 changes: 2 additions & 0 deletions backend/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ def create_application():
################################################
# Heartbeat
################################################
@home.route("/api/heartbeat", methods=["GET"])
@home.route("/heartbeat", methods=["GET"])
def r_heartbeat():
return jsonify({"heartbeat": "OK"})
Expand All @@ -126,6 +127,7 @@ def r_heartbeat():
# Question
################################################
@home.route("/api/question", methods=["POST"])
@home.route("/question", methods=["POST"])
def r_question(embedder = embedder, query_engine = query_engine):
json_result = request.get_json()
user_query = json_result.get("question", "")
Expand Down

0 comments on commit 1d550d1

Please sign in to comment.