Skip to content

Commit

Permalink
push
Browse files Browse the repository at this point in the history
  • Loading branch information
humanagent committed Dec 24, 2024
1 parent f128a37 commit 264cebd
Show file tree
Hide file tree
Showing 4 changed files with 283 additions and 15 deletions.
1 change: 1 addition & 0 deletions agent/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
"@ai16z/eliza": "workspace:*",
"@ai16z/plugin-0g": "workspace:*",
"@ai16z/plugin-aptos": "workspace:*",
"@ai16z/plugin-concierge": "workspace:*",
"@ai16z/plugin-bootstrap": "workspace:*",
"@ai16z/plugin-intiface": "workspace:*",
"@ai16z/plugin-coinbase": "workspace:*",
Expand Down
19 changes: 11 additions & 8 deletions packages/client-telegram/src/messageManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1053,21 +1053,22 @@ export class MessageManager {

if (shouldRespond) {
// Generate response
const template =
this.runtime.character.templates
?.telegramMessageHandlerTemplate ||
this.runtime.character?.templates?.messageHandlerTemplate ||
telegramMessageHandlerTemplate;
const context = composeContext({
state,
template,
template:
this.runtime.character.templates
?.telegramMessageHandlerTemplate ||
this.runtime.character?.templates
?.messageHandlerTemplate ||
telegramMessageHandlerTemplate,
});

const responseContent = await this._generateResponse(
memory,
state,
context
);
console.log("checkpoint 3", responseContent);

if (!responseContent || !responseContent.text) return;

// Send response in chunks
Expand Down Expand Up @@ -1124,12 +1125,14 @@ export class MessageManager {
state = await this.runtime.updateRecentMessageState(state);

// Handle any resulting actions
await this.runtime.processActions(

const actionResult: any = await this.runtime.processActions(
memory,
responseMessages,
state,
callback
);
console.log("actionResult", actionResult);
}

await this.runtime.evaluate(memory, state, shouldRespond);
Expand Down
2 changes: 0 additions & 2 deletions packages/plugin-concierge/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,4 @@ export const conciergePlugin: Plugin = {
transferAction,
swapAction,
],

// Add evaluators and providers if needed
};
Loading

0 comments on commit 264cebd

Please sign in to comment.