Skip to content

Commit a395ba1

Browse files
authored
Merge pull request #545 from bmgalego/more-fixes
fix: error in getGoals and remove coinbase package-lock.json
2 parents a0b3f4b + ae97d6e commit a395ba1

File tree

6 files changed

+6
-3981
lines changed

6 files changed

+6
-3981
lines changed

packages/adapter-postgres/src/index.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -344,7 +344,7 @@ export class PostgresDatabaseAdapter
344344
}): Promise<Memory[]> {
345345
if (!params.tableName) throw new Error("tableName is required");
346346
if (!params.roomId) throw new Error("roomId is required");
347-
let sql = `SELECT * FROM memories WHERE type = $1 AND agentId = $2 AND "roomId" = $3`;
347+
let sql = `SELECT * FROM memories WHERE type = $1 AND "agentId" = $2 AND "roomId" = $3`;
348348
const values: any[] = [params.tableName, params.agentId, params.roomId];
349349
let paramCount = 2;
350350

packages/adapter-postgres/tsconfig.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22
"extends": "../../tsconfig.json",
33
"compilerOptions": {
44
"outDir": "dist",
5-
"rootDir": "src"
5+
"rootDir": "src",
6+
"strict": true
67
},
78
"include": ["src/**/*.ts"]
89
}

packages/adapter-sqlite/tsconfig.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22
"extends": "../../tsconfig.json",
33
"compilerOptions": {
44
"outDir": "dist",
5-
"rootDir": "src"
5+
"rootDir": "src",
6+
"strict": true
67
},
78
"include": ["src/**/*.ts"]
89
}

packages/core/src/goals.ts

+1-3
Original file line numberDiff line numberDiff line change
@@ -6,22 +6,20 @@ import {
66
} from "./types.ts";
77

88
export const getGoals = async ({
9-
agentId,
109
runtime,
1110
roomId,
1211
userId,
1312
onlyInProgress = true,
1413
count = 5,
1514
}: {
1615
runtime: IAgentRuntime;
17-
agentId: UUID;
1816
roomId: UUID;
1917
userId?: UUID;
2018
onlyInProgress?: boolean;
2119
count?: number;
2220
}) => {
2321
return runtime.databaseAdapter.getGoals({
24-
agentId,
22+
agentId: runtime.agentId,
2523
roomId,
2624
userId,
2725
onlyInProgress,

packages/core/src/runtime.ts

-1
Original file line numberDiff line numberDiff line change
@@ -741,7 +741,6 @@ export class AgentRuntime implements IAgentRuntime {
741741
unique: false,
742742
}),
743743
getGoals({
744-
agentId: this.agentId,
745744
runtime: this,
746745
count: 10,
747746
onlyInProgress: false,

0 commit comments

Comments
 (0)