Skip to content

Commit

Permalink
Prereplease
Browse files Browse the repository at this point in the history
  • Loading branch information
LucasB25 committed May 1, 2024
1 parent c5c281a commit 923807d
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 4 deletions.
5 changes: 4 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,7 @@ TOKEN= #Discord Bot Token
CLIENT_ID= #Discord Bot Client ID
COLOR=#00ff00
REPLICATE_TOKEN= #Replicate Token from https://replicate.com/signin
MODEL=bytedance/sdxl-lightning-4step:727e49a643e999d602a896c774a0658ffefea21465756a6ce24b7ea4165eba6a
REPLICATE_MODEL=bytedance/sdxl-lightning-4step:727e49a643e999d602a896c774a0658ffefea21465756a6ce24b7ea4165eba6a

GOOGLE_KEY= #Google key from https://makersuite.google.com/
GOOGLE_MODEL=gemini-1.5-pro-latest
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ TOKEN= #Discord Bot Token
CLIENT_ID= #Discord Bot Client ID
COLOR=#00ff00
REPLICATE_TOKEN= #Replicate Token from https://replicate.com/signin
MODEL=bytedance/sdxl-lightning-4step:727e49a643e999d602a896c774a0658ffefea21465756a6ce24b7ea4165eba6a
REPLICATE_MODEL=bytedance/sdxl-lightning-4step:727e49a643e999d602a896c774a0658ffefea21465756a6ce24b7ea4165eba6a
```

5. Run the bot:
Expand Down
2 changes: 1 addition & 1 deletion src/commands/imagine/Imagine.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ export default class Imagine extends Command {
await interaction.deferReply({ fetchReply: true });
await interaction.editReply({ content: `**${prompt}** - ${interaction.user.toString()}` });

const prediction = (await client.replicate.run(this.client.config.model, {
const prediction = (await client.replicate.run(this.client.config.replicateModel, {
input: {
prompt: prompt,
num_outputs: numOutputs,
Expand Down
6 changes: 5 additions & 1 deletion src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,9 @@ export default {
clientId: process.env.CLIENT_ID,
color: process.env.COLOR,
replicateToken: process.env.REPLICATE_TOKEN,
model: process.env.MODEL as any,
replicateModel: process.env.REPLICATE_MODEL as any,

googleKey: process.env.GOOGLE_KEY,
googleModel: process.env.GOOGLE_MODEL as any,
proxy: process.env.LOCAL_FETCH_PROXY as any,
};

0 comments on commit 923807d

Please sign in to comment.