Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WebService usage help #3626

Open
lokendrasurya opened this issue Feb 21, 2025 · 1 comment
Open

WebService usage help #3626

lokendrasurya opened this issue Feb 21, 2025 · 1 comment

Comments

@lokendrasurya
Copy link

lokendrasurya commented Feb 21, 2025

I am trying to improve the quality if tweet post, so make it aware of recent info, I wanted to integrate tavily in twitter post generation.
I imported web-search plugin and trying to access WebSearchService as mentioned here. in packages/client-twitter/src/post.ts

But it is not working. I have imported plugin at top

import { webSearchPlugin } from "../../plugin-web-search";

and below is the code I am trying to use.

for (const searchQuery of searchTermList) {
            //code to do web search

            const webSearchService = new WebSearchService();
            await webSearchService.initialize(runtime);
            const results = await webSearchService.search(
                searchQuery
                // searchOptions
            );
 }

I am getting error in importing only showing
Cannot find name 'WebSearchService'. Did you mean 'webSearchService'?ts(2552)

Is there any different approach should I follow ?

Copy link
Contributor

Hello @lokendrasurya! Welcome to the elizaOS community. Thank you for opening your first issue; we appreciate your contribution. You are now an elizaOS contributor!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant