Ahmed007 commited on
Commit
b2b346c
·
verified ·
1 Parent(s): fc6816d

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +5 -4
main.py CHANGED
@@ -27,13 +27,13 @@ def get_skills():
27
  cv_body = request.json.get('cv_body')
28
 
29
  template = """Instruct:
30
- Take a deep breath to deep understand, and don't this cv vc = {cv_body} . to answer this question and instructions </s> {question}
31
  \nOutput:"""
32
 
33
- prompt = PromptTemplate(template=template, input_variables=["question","text"])
34
  chain = prompt | llm | StrOutputParser()
35
 
36
- ans = chain.invoke({"question": "What are his best skills? write in points","text":cv_body},
37
  config={
38
  # "callbacks": [ConsoleCallbackHandler()]
39
  })
@@ -41,4 +41,5 @@ def get_skills():
41
  return jsonify({'skills': ans})
42
 
43
  if __name__ == '__main__':
44
- app.run()
 
 
27
  cv_body = request.json.get('cv_body')
28
 
29
  template = """Instruct:
30
+ Take a deep breath to deep understand, and don't this cv vc = {cv_body} . to answer this question and instructions </s>
31
  \nOutput:"""
32
 
33
+ prompt = PromptTemplate(template=template, input_variables=["text"])
34
  chain = prompt | llm | StrOutputParser()
35
 
36
+ ans = chain.invoke({"question": "What are his best skills? write in points","cv_body":cv_body},
37
  config={
38
  # "callbacks": [ConsoleCallbackHandler()]
39
  })
 
41
  return jsonify({'skills': ans})
42
 
43
  if __name__ == '__main__':
44
+ app.run()
45
+