Skip to content

Commit

Permalink
Use topic id as number
Browse files Browse the repository at this point in the history
  • Loading branch information
conache committed Jan 7, 2025
1 parent 0e860b5 commit df2c235
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/plugin-allora/src/actions/getInference.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ export const getInferenceAction: Action = {

// Define the schema for extracting the inference fields
const schema = z.object({
topicId: z.string().nullable(),
topicId: z.number().nullable(),
topicName: z.string().nullable(),
});

Expand Down
4 changes: 2 additions & 2 deletions packages/plugin-allora/src/templates/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ export const getInferenceTemplate = `Respond with a JSON markdown block containi
Example response:
\`\`\`json
{
"topicId": "1",
"topicId": 1,
"topicName": "Topic Name",
}
\`\`\`
Expand All @@ -22,7 +22,7 @@ If the topic is not active or the prediction timeframe is not matching the user'
Respond with a JSON markdown block containing only the extracted values. Use null for any values that cannot be determined. The result should be a valid JSON object with the following schema:
\`\`\`json
{
"topicId": string | null,
"topicId": number | null,
"topicName": string | null,
}
\`\`\``;

0 comments on commit df2c235

Please sign in to comment.