diff --git a/README.md b/README.md index 250c62d..06016ed 100644 --- a/README.md +++ b/README.md @@ -1 +1,16 @@ -# replyguy +# ReplyGuy + +ReplyGuy is an agent on farcaster that helps you in discovering most relevant content as per your each cast. + +## Features + +1. Content Discovery on the Farcaster. +2. Verifiability of the data fetched from the farcaster using Reclaim Protocol. +3. Verifiability of the cast created by the agent using the custom Eigen Layer built using Othentic stack on Base and Ethereum. + +## Tech Stack + +1. Farcaster profile. +2. Eigen Layer AVS on Base and Ethereum. +3. Gemini and OpenAI for generating embeddings and replies. +4. Supabase for storing the data. diff --git a/backend/MCP_Execution_Server/src/services/db.service.ts b/backend/MCP_Execution_Server/src/services/db.service.ts index a089aba..2728d73 100644 --- a/backend/MCP_Execution_Server/src/services/db.service.ts +++ b/backend/MCP_Execution_Server/src/services/db.service.ts @@ -191,11 +191,11 @@ export class DBService { } } - async addCastReply(cast_hash: string) { + async addCastReply(cast_hash: string, cast_reply_hash: string) { try { const { data, error } = await this.supabase .from("cast_replies") - .insert([{ cast_hash }]); + .insert({ cast_hash, cast_reply_hash }); if (error) throw error; return { success: true, data }; } catch (err: any) { diff --git a/backend/MCP_Execution_Server/src/services/user.service.ts b/backend/MCP_Execution_Server/src/services/user.service.ts index 5f170d4..56dea2c 100644 --- a/backend/MCP_Execution_Server/src/services/user.service.ts +++ b/backend/MCP_Execution_Server/src/services/user.service.ts @@ -15,7 +15,7 @@ export class UserService { private aiService: AIService, private db: DBService, private geminiService?: GeminiAiService, - ) {} + ) { } private async summarizeUserContextSafe( userData: any, @@ -240,7 +240,7 @@ export class UserService { } async registerCast(fid: string, cast: any) { - console.log("registering cast"); + console.log("registering cast", `https://warpcast.com/yourreplyguy/${cast.hash}`); if (cast.text === "") { console.log("Cast text is empty, skipping"); @@ -318,7 +318,7 @@ export class UserService { if ( aiResponse.replyText === - "No relevant trending casts found in the provided data." || + "No relevant trending casts found in the provided data." || aiResponse.replyText === "No response needed for this cast." || aiResponse.link === "" ) { @@ -336,9 +336,8 @@ export class UserService { ], }); - console.log("Cast replied"); - await this.db.addCastReply(castReply.cast.hash); - console.log(aiResponse); + console.log("Cast replied", `https://warpcast.com/yourreplyguy/${castReply.cast.hash}`); + await this.db.addCastReply(cast.hash, castReply.cast.hash); return { success: true, data: aiResponse }; } catch (err: any) { console.error("registerCast error", err); diff --git a/backend/docker-compose.yml b/backend/docker-compose.yml index f990d61..5ba2921 100644 --- a/backend/docker-compose.yml +++ b/backend/docker-compose.yml @@ -18,8 +18,6 @@ services: "--l2-chain", "base-sepolia", "--internal-tasks", - "--sync-interval", - "5400000", ] environment: - PRIVATE_KEY=${PRIVATE_KEY_AGGREGATOR}