Skip to content

Commit ea3670a

Browse files
authored
Merge pull request #2027 from elizaOS/remove-defillama-plugin
fix: remove defillama plugin & improve rabbi trader
2 parents 0e74e13 + b2abd16 commit ea3670a

File tree

23 files changed

+1677
-1643
lines changed

23 files changed

+1677
-1643
lines changed

packages/client-twitter/src/base.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -361,7 +361,7 @@ export class ClientBase extends EventEmitter {
361361
.slice(0, count);
362362
// TODO: Once the 'count' parameter is fixed in the 'fetchTimeline' method of the 'agent-twitter-client',
363363
// this workaround can be removed.
364-
// Related issue: https://github.com/elizaOS/agent-twitter-client/issues/43
364+
// Related issue: https://github.com/elizaos/agent-twitter-client/issues/43
365365
}
366366

367367
async fetchSearchTweets(

packages/plugin-coinmarketcap/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,4 +124,4 @@ For support, please open an issue in the repository or reach out to the maintain
124124

125125
- [CoinMarketCap API Documentation](https://coinmarketcap.com/api/documentation/v1/)
126126

127-
- [GitHub Repository](https://github.com/elizaOS/eliza/tree/main/packages/plugin-coinmarketcap)
127+
- [GitHub Repository](https://github.com/elizaos/eliza/tree/main/packages/plugin-coinmarketcap)

packages/plugin-coinprice/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -131,4 +131,4 @@ For support, please open an issue in the repository or reach out to the maintain
131131
- [CoinGecko API Documentation](https://www.coingecko.com/en/api)
132132
- [CoinCap API Documentation](https://docs.coincap.io/)
133133
- [CoinMarketCap API Documentation](https://coinmarketcap.com/api/documentation/v1/)
134-
- [GitHub Repository](https://github.com/elizaOS/eliza/tree/main/packages/plugin-coinprice)
134+
- [GitHub Repository](https://github.com/elizaos/eliza/tree/main/packages/plugin-coinprice)

packages/plugin-defillama/README.md

Whitespace-only changes.

packages/plugin-defillama/package.json

-29
This file was deleted.

packages/plugin-defillama/src/actions/get-price.action.ts

-18
This file was deleted.

packages/plugin-defillama/src/environment.ts

-8
This file was deleted.

packages/plugin-defillama/src/index.ts

-14
This file was deleted.

packages/plugin-defillama/src/providers/defillama.provider.ts

-24
This file was deleted.

packages/plugin-defillama/tsconfig.json

-10
This file was deleted.

packages/plugin-defillama/tsup.config.ts

-17
This file was deleted.

packages/plugin-letzai/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
![LetzAI Logo](https://letz.ai/_next/image?url=%2FL.png&w=64&q=100)
44

5-
A plugin to integrate LetzAI Image Generation capabilities into the elizaOS ecosystem.
5+
A plugin to integrate LetzAI Image Generation capabilities into the elizaos ecosystem.
66

77
It uses the [LetzAI API](https://www.letz.ai/docs/api) and can use any models available to API user.
88

packages/plugin-node/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ import { createNodePlugin } from "@elizaos/plugin-node";
6565
const nodePlugin = createNodePlugin();
6666

6767
// Register with Eliza OS
68-
elizaOS.registerPlugin(nodePlugin);
68+
elizaos.registerPlugin(nodePlugin);
6969
```
7070

7171
## Services

packages/plugin-obsidian/src/example/NAVALS-VAULT.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ https://drive.google.com/drive/folders/1EZiUhASpNQBYka3Z8NNkBzYnrb7TCfmG
3131
- Install the Obsidian Rest API plugin and activate it
3232
- Copy the API token from the plugin settings
3333
- Setup the agent with the API token and the Vault Rest API URL
34-
- Run the elizaOS agent
34+
- Run the elizaos agent
3535
- Prompt the agent to create the knowledge base (Take a couple minutes to complete): **"Create knowledge base"**
3636

3737
Have fun talking to Naval's digital brain!

packages/plugin-rabbi-trader/package.json

+7-7
Original file line numberDiff line numberDiff line change
@@ -6,18 +6,18 @@
66
"types": "dist/index.d.ts",
77
"dependencies": {
88
"@elizaos/core": "workspace:*",
9-
"@elizaos/client-twitter":"workspace:*",
10-
"@elizaos/plugin-solana":"workspace:*",
11-
"@elizaos/plugin-trustdb":"workspace:*",
9+
"@elizaos/client-twitter": "workspace:*",
10+
"@elizaos/plugin-solana": "workspace:*",
11+
"@elizaos/plugin-trustdb": "workspace:*",
1212
"@solana/web3.js": "^1.87.6",
13-
"zod":"3.23.8",
13+
"zod": "3.23.8",
1414
"@goat-sdk/core": "0.3.8",
1515
"@goat-sdk/plugin-erc20": "0.1.7",
1616
"@goat-sdk/wallet-viem": "0.1.3",
17-
"node-cache": "^5.1.2",
18-
"bignumber": "1.1.0",
17+
"node-cache": "^5.1.2",
18+
"bignumber": "1.1.0",
1919
"bignumber.js": "9.1.2",
20-
"@goat-sdk/plugin-coingecko":"0.1.4",
20+
"@goat-sdk/plugin-coingecko": "0.1.4",
2121
"tsup": "8.3.5",
2222
"ws": "^8.0.0"
2323
},
Original file line numberDiff line numberDiff line change
@@ -1,47 +1,47 @@
11
import {
2-
Action,
3-
composeContext,
4-
elizaLogger,
5-
generateText,
6-
ModelClass,
7-
parseJSONObjectFromText,
8-
} from "@elizaOS/core";
2+
Action,
3+
composeContext,
4+
elizaLogger,
5+
generateText,
6+
ModelClass,
7+
parseJSONObjectFromText,
8+
} from "@elizaos/core";
99

1010
export const analyzeTradeAction: Action = {
11-
name: "ANALYZE_TRADE",
12-
description: "Analyze a token for trading opportunities",
13-
similes: [
14-
"ANALYZE",
15-
"ANALYZE_TOKEN",
16-
"TRADE",
17-
"ANALYZE_TRADE",
18-
"EVALUATE",
19-
"ASSESS",
20-
],
21-
examples: [],
22-
validate: async () => true,
23-
handler: async (runtime, memory, state, params, callback) => {
24-
try {
25-
// composeState
26-
if (!state) {
27-
state = await runtime.composeState(memory);
28-
} else state = await runtime.updateRecentMessageState(state);
11+
name: "ANALYZE_TRADE",
12+
description: "Analyze a token for trading opportunities",
13+
similes: [
14+
"ANALYZE",
15+
"ANALYZE_TOKEN",
16+
"TRADE",
17+
"ANALYZE_TRADE",
18+
"EVALUATE",
19+
"ASSESS",
20+
],
21+
examples: [],
22+
validate: async () => true,
23+
handler: async (runtime, memory, state, params, callback) => {
24+
try {
25+
// composeState
26+
if (!state) {
27+
state = await runtime.composeState(memory);
28+
} else state = await runtime.updateRecentMessageState(state);
2929

30-
const tokenData = {
31-
walletBalance: params.walletBalance,
32-
tokenAddress: params.tokenAddress,
33-
price: params.price,
34-
volume: params.volume,
35-
marketCap: params.marketCap,
36-
liquidity: params.liquidity,
37-
holderDistribution: params.holderDistribution,
38-
trustScore: params.trustScore,
39-
dexscreener: params.dexscreener,
40-
position: params.position,
41-
};
30+
const tokenData = {
31+
walletBalance: params.walletBalance,
32+
tokenAddress: params.tokenAddress,
33+
price: params.price,
34+
volume: params.volume,
35+
marketCap: params.marketCap,
36+
liquidity: params.liquidity,
37+
holderDistribution: params.holderDistribution,
38+
trustScore: params.trustScore,
39+
dexscreener: params.dexscreener,
40+
position: params.position,
41+
};
4242

43-
// Direct prompt instead of template
44-
const prompt = `Analyze the following token data and provide a trading recommendation.
43+
// Direct prompt instead of template
44+
const prompt = `Analyze the following token data and provide a trading recommendation.
4545
Return the response as a JSON object with the following structure:
4646
{
4747
"recommendation": "BUY" | "SELL" | "HOLD",
@@ -54,41 +54,41 @@ Return the response as a JSON object with the following structure:
5454
Token Data:
5555
${JSON.stringify(tokenData, null, 2)}`;
5656

57-
// Generate analysis using direct prompt
58-
const content = await generateText({
59-
runtime,
60-
context: prompt,
61-
modelClass: ModelClass.LARGE,
62-
});
57+
// Generate analysis using direct prompt
58+
const content = await generateText({
59+
runtime,
60+
context: prompt,
61+
modelClass: ModelClass.LARGE,
62+
});
6363

64-
if (!content) {
65-
throw new Error("No analysis generated");
66-
}
64+
if (!content) {
65+
throw new Error("No analysis generated");
66+
}
6767

68-
elizaLogger.log(`Raw analysis response:`, content);
68+
elizaLogger.log(`Raw analysis response:`, content);
6969

70-
// Parse the response to get the recommended action
71-
const recommendation = parseJSONObjectFromText(content);
72-
elizaLogger.log(
73-
`Parsed recommendation for ${params.tokenAddress}:`,
74-
recommendation,
75-
);
70+
// Parse the response to get the recommended action
71+
const recommendation = parseJSONObjectFromText(content);
72+
elizaLogger.log(
73+
`Parsed recommendation for ${params.tokenAddress}:`,
74+
recommendation
75+
);
7676

77-
// Send result through callback
78-
if (callback) {
79-
await callback({
80-
text: JSON.stringify(recommendation),
81-
type: "analysis",
82-
});
83-
}
77+
// Send result through callback
78+
if (callback) {
79+
await callback({
80+
text: JSON.stringify(recommendation),
81+
type: "analysis",
82+
});
83+
}
8484

85-
return true;
86-
} catch (error) {
87-
elizaLogger.error(`Analysis failed:`, {
88-
error: error instanceof Error ? error.message : "Unknown error",
89-
stack: error instanceof Error ? error.stack : undefined,
90-
});
91-
return false;
92-
}
93-
},
85+
return true;
86+
} catch (error) {
87+
elizaLogger.error(`Analysis failed:`, {
88+
error: error instanceof Error ? error.message : "Unknown error",
89+
stack: error instanceof Error ? error.stack : undefined,
90+
});
91+
return false;
92+
}
93+
},
9494
};

0 commit comments

Comments
 (0)