Skip to content

Commit

Permalink
Reference removal (#127)
Browse files Browse the repository at this point in the history
* Removes unused doc ock reference

* Removes start stript env var
  • Loading branch information
JWittmeyer authored Oct 17, 2024
1 parent 64b515a commit 60d0ca2
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 77 deletions.
7 changes: 0 additions & 7 deletions controller.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
import zlib
from spacy.tokens import DocBin, Doc
from spacy.vocab import Vocab
from data import doc_ock
from embedders import Transformer
from typing import Any, Dict, Iterator, List, Optional

Expand Down Expand Up @@ -157,7 +156,6 @@ def __prepare_encoding(project_id: str, embedding_id: str) -> None:
f"notification_created:{user_id}",
True,
)
doc_ock.post_embedding_failed(user_id, f"{model}-{platform}")
raise Exception(message)
return (
project_id,
Expand Down Expand Up @@ -244,7 +242,6 @@ def run_encoding(
project_id,
f"embedding:{embedding_id}:state:{enums.EmbeddingState.FAILED.value}",
)
doc_ock.post_embedding_failed(user_id, f"{model}-{platform}")
notification_message = f"Error while getting model - {e}"
notification.create(
project_id,
Expand Down Expand Up @@ -276,7 +273,6 @@ def run_encoding(
project_id,
f"embedding:{embedding_id}:state:{enums.EmbeddingState.ENCODING.value}",
)
doc_ock.post_embedding_encoding(user_id, f"{model}-{platform}")
notification.create(
project_id,
user_id,
Expand Down Expand Up @@ -346,7 +342,6 @@ def run_encoding(
enums.NotificationType.EMBEDDING_CREATION_FAILED.value,
True,
)
doc_ock.post_embedding_failed(user_id, f"{model}-{platform}")
return status.HTTP_500_INTERNAL_SERVER_ERROR
except Exception as e:
error_message = str(e)
Expand Down Expand Up @@ -409,7 +404,6 @@ def run_encoding(
True,
)
send_project_update(project_id, f"notification_created:{user_id}", True)
doc_ock.post_embedding_failed(user_id, f"{model}-{platform}")
return status.HTTP_500_INTERNAL_SERVER_ERROR

if embedding.get(project_id, embedding_id) and not embedding_canceled:
Expand Down Expand Up @@ -471,7 +465,6 @@ def run_encoding(
True,
)
send_project_update(project_id, f"notification_created:{user_id}", True)
doc_ock.post_embedding_finished(user_id, f"{model}-{platform}")
general.commit()
general.remove_and_refresh_session(session_token)
return status.HTTP_200_OK
Expand Down
69 changes: 0 additions & 69 deletions data/doc_ock.py

This file was deleted.

1 change: 0 additions & 1 deletion start
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ docker run -d --rm \
-e S3_ACCESS_KEY=kern \
-e S3_SECRET_KEY=r6ywtR33!DMlaL*SUUdy \
-e POSTGRES=postgresql://postgres:kern@graphql-postgres:5432 \
-e DOC_OCK=http://refinery-doc-ock:80 \
-e MODEL_PROVIDER=http://refinery-model-provider:80 \
-e WS_NOTIFY_ENDPOINT="http://refinery-websocket:8080" \
-e NEURAL_SEARCH=http://refinery-neural-search:80 \
Expand Down

0 comments on commit 60d0ca2

Please sign in to comment.