Skip to content

Commit

Permalink
Merge pull request #36 from Knox-AAU/concept-linking
Browse files Browse the repository at this point in the history
Fixed some bugs in docker
  • Loading branch information
denBruneBarone authored Dec 15, 2023
2 parents cc1894e + d276902 commit 03f0934
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
9 changes: 6 additions & 3 deletions concept_linking/solutions/PromptEngineering/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,16 @@
from relation_extraction.knowledge_graph_messenger import KnowledgeGraphMessenger
from concept_linking.tools.triple_helper import *

# Local API url
# Local API url python
api_url = "http://127.0.0.1:5000/llama"

# Local API url docker
# api_url = "http://llama-cpu-server:5000/llama"

# Remote API url
# api_url = "http://knox-proxy01.srv.aau.dk/llama-api/llama"

headers = {"Content-Type": "application/json"}
headers = {"Access-Authorization": os.getenv("ACCESS_SECRET"), "Content-Type": "application/json"}

PROJECT_ROOT = os.path.abspath(os.path.join(os.path.dirname(__file__), "../../"))

Expand Down Expand Up @@ -181,7 +184,7 @@ def perform_entity_type_classification(post_json, output_file_path=None, output_


if __name__ == '__main__':
input_file = os.path.join(PROJECT_ROOT, "data/files/EvaluationData/evaluationSet_EN.json")
input_file = os.path.join(PROJECT_ROOT, "data/files/EvaluationData/evaluationSet_EN_small.json")
output_file = os.path.join(PROJECT_ROOT, "data/files/PromptEngineering/output.json")

f = open(input_file, encoding="utf-8")
Expand Down
2 changes: 1 addition & 1 deletion concept_linking/tools/LlamaServer/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ services:
volumes:
- ./concept_linking/tools/LlamaServer/llama-2-7b-chat.Q2_K.gguf:/app/concept_linking/tools/LlamaServer/llama-2-7b-chat.Q2_K.gguf
ports:
- "5000:5000"
- "5000:5000"

0 comments on commit 03f0934

Please sign in to comment.