clean up `Anthropic`

pull/53/head
Kye 1 year ago
parent faf17487c2
commit 1a1c5ad74b

@ -2,7 +2,7 @@ from swarms import Worker
node = Worker(
openai_api_key="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",
openai_api_key="",
ai_name="Optimus Prime",
)

@ -4,7 +4,16 @@ import os
class Anthropic:
"""Anthropic large language models."""
def __init__(self, model="claude-2", max_tokens_to_sample=256, temperature=None, top_k=None, top_p=None, streaming=False, default_request_timeout=None):
def __init__(
self,
model="claude-2",
max_tokens_to_sample=256,
temperature=None,
top_k=None,
top_p=None,
streaming=False,
default_request_timeout=None
):
self.model = model
self.max_tokens_to_sample = max_tokens_to_sample
self.temperature = temperature

@ -8,7 +8,6 @@ from swarms.utils.decorators import error_decorator, log_decorator, timing_decor
# TODO Handle task assignment and task delegation
# TODO: User task => decomposed into very small sub tasks => sub tasks assigned to workers => workers complete and update the swarm, can ask for help from other agents.
# TODO: Missing, Task Assignment, Task delegation, Task completion, Swarm level communication with vector db
#
class AutoScaler:
@log_decorator

@ -1,5 +1,6 @@
import uuid
class Task:
def __init__(self, objective, priority=0, schedule=None, dependencies=None):
self.id = uuid.uuid4()

Loading…
Cancel
Save