Skip to content

Commit

Permalink
remove walletinfo from template
Browse files Browse the repository at this point in the history
  • Loading branch information
jacob-tucker committed Dec 11, 2024
1 parent 5595de8 commit c176e1e
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 31 deletions.
7 changes: 0 additions & 7 deletions packages/plugin-story/src/actions/attachTerms.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,13 +93,6 @@ export const attachTermsAction = {
state = await runtime.updateRecentMessageState(state);
}

const walletInfo = await storyWalletProvider.get(
runtime,
message,
state
);
state.walletInfo = walletInfo;

const attachTermsContext = composeContext({
state,
template: attachTermsTemplate,
Expand Down
7 changes: 0 additions & 7 deletions packages/plugin-story/src/actions/licenseIP.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,13 +64,6 @@ export const licenseIPAction = {
state = await runtime.updateRecentMessageState(state);
}

const walletInfo = await storyWalletProvider.get(
runtime,
message,
state
);
state.walletInfo = walletInfo;

const licenseIPContext = composeContext({
state,
template: licenseIPTemplate,
Expand Down
9 changes: 1 addition & 8 deletions packages/plugin-story/src/actions/registerIP.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ import { storyWalletProvider, WalletProvider } from "../providers/wallet";
import { registerIPTemplate } from "../templates";
import { RegisterIPParams } from "../types";
import { RegisterIpResponse } from "@story-protocol/core-sdk";
import { PinataProvider } from "../providers/pinata";
import { createHash } from "crypto";
import { PinataProvider } from "../providers/pinata";

export { registerIPTemplate };

Expand Down Expand Up @@ -88,13 +88,6 @@ export const registerIPAction = {
state = await runtime.updateRecentMessageState(state);
}

const walletInfo = await storyWalletProvider.get(
runtime,
message,
state
);
state.walletInfo = walletInfo;

const registerIPContext = composeContext({
state,
template: registerIPTemplate,
Expand Down
12 changes: 3 additions & 9 deletions packages/plugin-story/src/templates/index.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
export const registerIPTemplate = `Given the recent messages and wallet information below:
export const registerIPTemplate = `Given the recent messages below:
{{recentMessages}}
{{walletInfo}}
Extract the following information about the requested IP registration:
- Field "title": The title of your IP
- Field "description": The description of your IP
Expand All @@ -22,12 +20,10 @@ Respond with a JSON markdown block containing only the extracted values. A user
\`\`\`
`;

export const licenseIPTemplate = `Given the recent messages and wallet information below:
export const licenseIPTemplate = `Given the recent messages below:
{{recentMessages}}
{{walletInfo}}
Extract the following information about the requested IP licensing:
- Field "licensorIpId": The IP Asset that you want to mint a license from
- Field "licenseTermsId": The license terms that you want to mint a license for
Expand All @@ -44,12 +40,10 @@ Respond with a JSON markdown block containing only the extracted values. A user
\`\`\`
`;

export const attachTermsTemplate = `Given the recent messages and wallet information below:
export const attachTermsTemplate = `Given the recent messages below:
{{recentMessages}}
{{walletInfo}}
Extract the following information about attaching license terms to an IP Asset:
- Field "ipId": The IP Asset that you want to attach the license terms to
- Field "mintingFee": The fee to mint this license from the IP Asset.
Expand Down

0 comments on commit c176e1e

Please sign in to comment.