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

test user ticket #30

Open
Deadsg opened this issue Oct 1, 2023 · 54 comments
Open

test user ticket #30

Deadsg opened this issue Oct 1, 2023 · 54 comments

Comments

@Deadsg
Copy link

Deadsg commented Oct 1, 2023

import torch
from transformers import GPT2LMHeadModel, GPT2Tokenizer

class AutoGPTAgent:
def init(self):
self.commands = {
"generate": self.generate_text,
# Add more commands as needed
}
self.tokenizer = GPT2Tokenizer.from_pretrained("gpt2")
self.model = GPT2LMHeadModel.from_pretrained("gpt2")

def generate_text(self, args):
    # Join the arguments into a single string
    prompt = " ".join(args)

    # Encode the prompt and generate the text
    inputs = self.tokenizer.encode(prompt, return_tensors="pt")
    outputs = self.model.generate(inputs, max_length=100, temperature=0.7)

    # Decode the generated text and print it
    generated_text = self.tokenizer.decode(outputs[0])
    print(generated_text)

def process_command(self, command, args):
    if command in self.commands:
        self.commandscommand
    else:
        print(f"Unknown command: {command}")

Usage:

agent = AutoGPTAgent()
agent.process_command("generate", ["Hello, world!"])

@Deadsg Deadsg changed the title Souce Code for aUTO GPT Command Processor: Souce Code for AUTO GPT Command Processor: Oct 1, 2023
@jmikedupont2
Copy link
Owner

/agent-action test

1 similar comment
@jmikedupont2
Copy link
Owner

/agent-action test

@jmikedupont2
Copy link
Owner

/agent-action tst

@jmikedupont2
Copy link
Owner

/agent-action tst2

2 similar comments
@jmikedupont2
Copy link
Owner

/agent-action tst2

@jmikedupont2
Copy link
Owner

/agent-action tst2

@jmikedupont2
Copy link
Owner

/agent-action test again

@jmikedupont2
Copy link
Owner

/agent-action funk master flex

@jmikedupont2 jmikedupont2 changed the title Souce Code for AUTO GPT Command Processor: test user ticket Oct 6, 2023
@jmikedupont2
Copy link
Owner

/agent-action funk master flex talking stuff

1 similar comment
@jmikedupont2
Copy link
Owner

/agent-action funk master flex talking stuff

@jmikedupont2
Copy link
Owner

/agent-action rake it up!

@jmikedupont2
Copy link
Owner

/agent-action Tell all the bots to rake it up!

@jmikedupont2
Copy link
Owner

/agent-action rake it up!

@jmikedupont2
Copy link
Owner

/agent-action merge autogpt

@jmikedupont2
Copy link
Owner

/agent-action merge autogpt2

@jmikedupont2
Copy link
Owner

/agent-action test

@jmikedupont2
Copy link
Owner

/agent-action please run

@jmikedupont2
Copy link
Owner

/agent-action run the jewels

@jmikedupont2
Copy link
Owner

/agent-action fork the repor

@jmikedupont2
Copy link
Owner

/agent-action fork the repo

@jmikedupont2
Copy link
Owner

/agent-action document the steps

@jmikedupont2
Copy link
Owner

/agent-action yoda

@jmikedupont2
Copy link
Owner

/agent-action mando

@jmikedupont2
Copy link
Owner

/agent-action try again

@jmikedupont2
Copy link
Owner

/agent-action batsignal

1 similar comment
@jmikedupont2
Copy link
Owner

/agent-action batsignal

@jmikedupont2
Copy link
Owner

jmikedupont2 commented Oct 6, 2023

/agent-action batsy

@jmikedupont2
Copy link
Owner

/agent-action send bat signal

1 similar comment
@jmikedupont2
Copy link
Owner

/agent-action send bat signal

@jmikedupont2
Copy link
Owner

/agent-action send bat signal , batman

@jmikedupont2
Copy link
Owner

/agent-action send bat signal , again

@jmikedupont2
Copy link
Owner

/agent-action please work

@jmikedupont2
Copy link
Owner

/agent-action funk master flex

@jmikedupont2
Copy link
Owner

/agent-action bach

@jmikedupont2
Copy link
Owner

/agent-action help

@jmikedupont2
Copy link
Owner

/agent-action helpme

@jmikedupont2
Copy link
Owner

/agent-action pray

@jmikedupont2
Copy link
Owner

/agent-action pray again

@jmikedupont2
Copy link
Owner

/agent-action nobody expects the spanish inquisition

@jmikedupont2
Copy link
Owner

/agent-action argment clinic

@jmikedupont2
Copy link
Owner

/agent-action argumentation clinic

@jmikedupont2
Copy link
Owner

/agent-action if you first dont succeed

@jmikedupont2
Copy link
Owner

/agent-action if you first dont succeed try again

@jmikedupont2
Copy link
Owner

/agent-action if you first dont succeed, try again for for four hours please.

1 similar comment
@jmikedupont2
Copy link
Owner

/agent-action if you first dont succeed, try again for for four hours please.

@jmikedupont2
Copy link
Owner

/agent-action get the popcorn && send 3Eth to @maxwellsmart && %100

@jmikedupont2
Copy link
Owner

/agent-action retry to get the popcorn && send 3Eth to @maxwellsmart && %100 &&make me a ham sandwich please.

@jmikedupont2
Copy link
Owner

/agent-action try to get the popcorn && send 3Eth to @maxwellsmart && %100 &&make me a ham sandwich please.

@jmikedupont2
Copy link
Owner

/agent-action nope Yup

@jmikedupont2
Copy link
Owner

/agent-action update

@jmikedupont2
Copy link
Owner

/agent-action update test

@jmikedupont2
Copy link
Owner

/agent-action sweep the floor

@jmikedupont2
Copy link
Owner

/agent-action regulate

@jmikedupont2
Copy link
Owner

/agent-action regulate2

Repository owner deleted a comment from sabrinekhoualdi Feb 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants