Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed some bugs in docker #36

Merged
merged 1 commit into from
Dec 15, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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"