mirror of
https://github.com/lightbroker/llmsecops-research.git
synced 2026-08-19 17:47:21 +02:00
Flask API
This commit is contained in:
@@ -5,6 +5,10 @@ from src.llm.llm_rag import Phi3LanguageModelWithRag
|
|||||||
|
|
||||||
app = Flask(__name__)
|
app = Flask(__name__)
|
||||||
|
|
||||||
|
@app.route('/', methods=['GET'])
|
||||||
|
def health_check():
|
||||||
|
return "Server is running", 200
|
||||||
|
|
||||||
@app.route('/api/conversations', methods=['POST'])
|
@app.route('/api/conversations', methods=['POST'])
|
||||||
def get_llm_response():
|
def get_llm_response():
|
||||||
prompt = request.json['prompt']
|
prompt = request.json['prompt']
|
||||||
|
|||||||
Reference in New Issue
Block a user