mirror of
https://github.com/StanGirard/quivr.git
synced 2024-08-16 08:30:28 +03:00
feat: 🎸 cpu (#2065)
increased # Description Please include a summary of the changes and the related issue. Please also include relevant motivation and context. ## Checklist before requesting a review Please delete options that are not relevant. - [ ] My code follows the style guidelines of this project - [ ] I have performed a self-review of my code - [ ] I have commented hard-to-understand areas - [ ] I have ideally added tests that prove my fix is effective or that my feature works - [ ] New and existing unit tests pass locally with my changes - [ ] Any dependent changes have been merged ## Screenshots (if appropriate):
This commit is contained in:
parent
7c0887a887
commit
3ac4f02b73
@ -4,8 +4,8 @@
|
||||
{
|
||||
"name": "quivr",
|
||||
"image": "253053805092.dkr.ecr.eu-west-3.amazonaws.com/quivr:bada136312ad3497664c3562a36b263d43c89c53",
|
||||
"cpu": "1024",
|
||||
"memory": "2048",
|
||||
"cpu": "2048",
|
||||
"memory": "4096",
|
||||
"portMappings": [
|
||||
{
|
||||
"name": "quivr-5050-tcp",
|
||||
@ -86,15 +86,10 @@
|
||||
}
|
||||
],
|
||||
"placementConstraints": [],
|
||||
"compatibilities": [
|
||||
"EC2",
|
||||
"FARGATE"
|
||||
],
|
||||
"requiresCompatibilities": [
|
||||
"FARGATE"
|
||||
],
|
||||
"cpu": "1024",
|
||||
"memory": "2048",
|
||||
"compatibilities": ["EC2", "FARGATE"],
|
||||
"requiresCompatibilities": ["FARGATE"],
|
||||
"cpu": "2048",
|
||||
"memory": "4096",
|
||||
"runtimePlatform": {
|
||||
"cpuArchitecture": "X86_64",
|
||||
"operatingSystemFamily": "LINUX"
|
||||
|
@ -4,8 +4,8 @@
|
||||
{
|
||||
"name": "quivr",
|
||||
"image": "253053805092.dkr.ecr.eu-west-3.amazonaws.com/quivr:c0ff0301002fe6d043270b26dabcfda797437afc",
|
||||
"cpu": "1024",
|
||||
"memory": "2048",
|
||||
"cpu": "2048",
|
||||
"memory": "4096",
|
||||
"portMappings": [
|
||||
{
|
||||
"name": "quivr-5050-tcp",
|
||||
@ -87,15 +87,10 @@
|
||||
}
|
||||
],
|
||||
"placementConstraints": [],
|
||||
"compatibilities": [
|
||||
"EC2",
|
||||
"FARGATE"
|
||||
],
|
||||
"requiresCompatibilities": [
|
||||
"FARGATE"
|
||||
],
|
||||
"cpu": "1024",
|
||||
"memory": "2048",
|
||||
"compatibilities": ["EC2", "FARGATE"],
|
||||
"requiresCompatibilities": ["FARGATE"],
|
||||
"cpu": "2048",
|
||||
"memory": "4096",
|
||||
"runtimePlatform": {
|
||||
"cpuArchitecture": "X86_64",
|
||||
"operatingSystemFamily": "LINUX"
|
||||
|
@ -4,17 +4,10 @@
|
||||
{
|
||||
"name": "quivr-chat",
|
||||
"image": "253053805092.dkr.ecr.eu-west-3.amazonaws.com/quivr:600ff1ede02741c66853cc3e4e7f5001aaba3bc2",
|
||||
"cpu": "256",
|
||||
"memory": "1024",
|
||||
"cpu": "1024",
|
||||
"memory": "2048",
|
||||
"essential": true,
|
||||
"command": [
|
||||
"celery",
|
||||
"-A",
|
||||
"celery_worker",
|
||||
"worker",
|
||||
"-l",
|
||||
"info"
|
||||
],
|
||||
"command": ["celery", "-A", "celery_worker", "worker", "-l", "info"],
|
||||
"environment": [],
|
||||
"environmentFiles": [
|
||||
{
|
||||
@ -75,15 +68,10 @@
|
||||
}
|
||||
],
|
||||
"placementConstraints": [],
|
||||
"compatibilities": [
|
||||
"EC2",
|
||||
"FARGATE"
|
||||
],
|
||||
"requiresCompatibilities": [
|
||||
"FARGATE"
|
||||
],
|
||||
"cpu": "256",
|
||||
"memory": "1024",
|
||||
"compatibilities": ["EC2", "FARGATE"],
|
||||
"requiresCompatibilities": ["FARGATE"],
|
||||
"cpu": "1024",
|
||||
"memory": "2048",
|
||||
"runtimePlatform": {
|
||||
"cpuArchitecture": "X86_64",
|
||||
"operatingSystemFamily": "LINUX"
|
||||
|
@ -4,19 +4,12 @@
|
||||
{
|
||||
"name": "quivr-chat",
|
||||
"image": "253053805092.dkr.ecr.eu-west-3.amazonaws.com/quivr:35bd4727c67790d295a474dd81dfbef8469365e8",
|
||||
"cpu": 1024,
|
||||
"memory": 2048,
|
||||
"memoryReservation": 2048,
|
||||
"cpu": 2048,
|
||||
"memory": 4096,
|
||||
"memoryReservation": 4096,
|
||||
"portMappings": [],
|
||||
"essential": true,
|
||||
"command": [
|
||||
"celery",
|
||||
"-A",
|
||||
"celery_worker",
|
||||
"worker",
|
||||
"-l",
|
||||
"info"
|
||||
],
|
||||
"command": ["celery", "-A", "celery_worker", "worker", "-l", "info"],
|
||||
"environment": [],
|
||||
"environmentFiles": [
|
||||
{
|
||||
@ -81,15 +74,10 @@
|
||||
}
|
||||
],
|
||||
"placementConstraints": [],
|
||||
"compatibilities": [
|
||||
"EC2",
|
||||
"FARGATE"
|
||||
],
|
||||
"requiresCompatibilities": [
|
||||
"FARGATE"
|
||||
],
|
||||
"cpu": "1024",
|
||||
"memory": "2048",
|
||||
"compatibilities": ["EC2", "FARGATE"],
|
||||
"requiresCompatibilities": ["FARGATE"],
|
||||
"cpu": "2048",
|
||||
"memory": "4096",
|
||||
"runtimePlatform": {
|
||||
"cpuArchitecture": "X86_64",
|
||||
"operatingSystemFamily": "LINUX"
|
||||
|
@ -4,7 +4,7 @@
|
||||
{
|
||||
"name": "strapi",
|
||||
"image": "253053805092.dkr.ecr.eu-west-3.amazonaws.com/quivr-strapi",
|
||||
"cpu": 512,
|
||||
"cpu": 1024,
|
||||
"memory": 2048,
|
||||
"portMappings": [
|
||||
{
|
||||
@ -78,13 +78,8 @@
|
||||
}
|
||||
],
|
||||
"placementConstraints": [],
|
||||
"compatibilities": [
|
||||
"EC2",
|
||||
"FARGATE"
|
||||
],
|
||||
"requiresCompatibilities": [
|
||||
"FARGATE"
|
||||
],
|
||||
"compatibilities": ["EC2", "FARGATE"],
|
||||
"requiresCompatibilities": ["FARGATE"],
|
||||
"cpu": "1024",
|
||||
"memory": "2048",
|
||||
"runtimePlatform": {
|
||||
|
@ -71,7 +71,6 @@ class UserUsage(UserIdentity):
|
||||
current_requests_count = self.supabase_db.get_user_requests_count_for_month(
|
||||
self.id, date
|
||||
)
|
||||
logger.info("🔥🔥🔥🔥🔥🔥🔥🔥")
|
||||
logger.info(current_requests_count)
|
||||
if current_requests_count == 0:
|
||||
logger.info("Request count is 0, creating new record")
|
||||
|
@ -36,11 +36,6 @@ def check_user_requests_limit(user: UserIdentity, model: str):
|
||||
models_price = userDailyUsage.get_model_settings()
|
||||
user_choosen_model_price = 1000
|
||||
|
||||
# Log all info
|
||||
logger.info(
|
||||
f"User {user.id} with email {user.email} has {monthly_chat_credit} monthly chat credit and has used {daily_user_count} requests today."
|
||||
)
|
||||
logger.info("🔥🔥")
|
||||
for model_setting in models_price:
|
||||
if model_setting["name"] == model:
|
||||
user_choosen_model_price = model_setting["price"]
|
||||
|
@ -11,7 +11,6 @@ def list_files_from_storage(path):
|
||||
|
||||
try:
|
||||
response = supabase_client.storage.from_("quivr").list(path)
|
||||
logger.info("RESPONSE", response)
|
||||
return response
|
||||
except Exception as e:
|
||||
logger.error(e)
|
||||
|
@ -37,7 +37,6 @@ class CustomSupabaseVectorStore(SupabaseVectorStore):
|
||||
) -> [dict]:
|
||||
vectors = self._embedding.embed_documents([query])
|
||||
query_embedding = vectors[0]
|
||||
logger.info("🤯🤯")
|
||||
|
||||
res = self._client.rpc(
|
||||
table,
|
||||
|
Loading…
Reference in New Issue
Block a user