Skip to content

Commit

Permalink
Merge commit '3c9352c58bcf9c4dd0c12aa4826bc7cbe14ad524' into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
DinisCruz committed Oct 16, 2024
2 parents f7b6880 + 3c9352c commit 528a43c
Show file tree
Hide file tree
Showing 22 changed files with 187 additions and 388 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

## Repo details

![Current Release](https://img.shields.io/badge/release-v0.2.8-blue)
![Current Release](https://img.shields.io/badge/release-v0.2.12-blue)
2 changes: 1 addition & 1 deletion deploy/docker/osbot-llms/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM python:3.12-slim

RUN pip install mangum uvicorn httpx openai numpy
RUN pip install osbot-aws osbot-fast-api
RUN pip install osbot-aws osbot-fast-api osbot-prefect

COPY --from=public.ecr.aws/awsguru/aws-lambda-adapter:0.8.4 /lambda-adapter /opt/extensions/lambda-adapter

Expand Down
3 changes: 2 additions & 1 deletion osbot_llms/OSBot_LLMs__Server_Config.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
from osbot_utils.base_classes.Type_Safe import Type_Safe

DEFAULT__SERVER_CONFIG__SERVER_NAME = 'osbot-llms'

class OSBot_LLMs__Server_Config(Type_Safe): # todo: add workflow to load this from a json/toml config file
s3_log_requests : bool = False
server_name : str = 'osbot-llms'
server_name : str = DEFAULT__SERVER_CONFIG__SERVER_NAME
s3_s3_use_minio : bool = True

osbot_llms__server_config = OSBot_LLMs__Server_Config()
1 change: 1 addition & 0 deletions osbot_llms/OSBot_LLMs__Shared_Objects.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ def s3_db_chat_threads(self): # to
kwargs = dict(use_minio = use_minio ,
server_name = server_name)
with S3_DB__Chat_Threads(**kwargs) as _:
_.bucket_name__insert_account_id = use_minio is False
_.setup() # set up tasks, including creating target bucket if it doesn't exist
_.s3_key_generator.use_request_path = False
_.s3_key_generator.use_when = True
Expand Down
198 changes: 0 additions & 198 deletions osbot_llms/backend/s3_minio/S3_DB_Base.py

This file was deleted.

84 changes: 0 additions & 84 deletions osbot_llms/backend/s3_minio/S3_DB_Base__Disabled.py

This file was deleted.

4 changes: 2 additions & 2 deletions osbot_llms/backend/s3_minio/S3_DB__Chat_Threads.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from osbot_aws.aws.s3.S3__DB_Base import S3__DB_Base
from osbot_utils.utils.Misc import timestamp_utc_now
from osbot_utils.utils.Status import status_ok, status_error
from osbot_llms.backend.s3_minio.S3_DB_Base import S3_DB_Base
from osbot_llms.backend.s3_minio.S3__Key__Chat_Thread import S3__Key__Chat_Thread
from osbot_llms.models.LLMs__Chat_Completion import LLMs__Chat_Completion

Expand All @@ -10,7 +10,7 @@
CHAT__REQUEST_TYPE__LLM_REQUEST = 'llm-request'
CHAT__REQUEST_TYPE__LLM_RESPONSE = 'llm-response'

class S3_DB__Chat_Threads(S3_DB_Base):
class S3_DB__Chat_Threads(S3__DB_Base):
bucket_name__suffix : str = S3_BUCKET_SUFFIX__CHAT_THREADS
save_as_gz : bool = True
s3_key_generator : S3__Key__Chat_Thread
Expand Down
5 changes: 4 additions & 1 deletion osbot_llms/fast_api/Fast_API__LLMs.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,11 @@


class Fast_API__LLMs(Fast_API):
base_path : str = '/llms'
base_path : str = '/llms'
enable_cors: bool = True

def setup_routes(self):
self.add_routes(Routes__Chat)
self.add_routes(Routes__Info)


Loading

0 comments on commit 528a43c

Please sign in to comment.