Inspiration
I've wanted to build an AI investment research web app for a few months now, but had other projects I was building. When I saw this hackathon I knew it was a good fit and time to implement the idea.
I had seen promising research and new projects in this space on X. It seemed the AI and investment communities were interested in the combination, e.g. trading decisions with bots, even if only paper trading.
What it does
The processes in AiTradefi:
- Define a named config that specifies an ElevenLabs voice.
- Define an analysis: what kind of investments they're looking for using free-form text.
- The analysis is used by an process that combines LLMs with finance data to find potential investments.
- Slideshows are generated for each investment with a high probability of success.
The ElevenLabs creative platform greatly enhances the experience:
- On the analysis page you can open a chat to get AI assistance, with options to hear the chat text as a spoken voice, or record your own voice to use as input for the chat.
- Slideshows are narrated by the voice selected for the chosen config.
- When choosing a voice for a config you can preview any of them.
How we built it
LLMs are used for chat, investment research and slideshow generation:
- Gemini 2.5 Flash (preview) for batch processing
- Gemini 2.5 Flash Lite for chat
ElevenLabs for AI audio:
- Text to speech (mostly narration, also optional for chats)
- Speech to text (optional for chat input)
Hosted on a Google Cloud VM.
Yahoo! Finance is used to supply relevant financial data.
The web app is built with Next.js + TypeScript. Libraries of note:
- Apollo GraphQL
- Prisma (ORM)
Two of my own Open Source libraries were utilized (deployed to project's repo):
- Serene Core: https://github.com/jfilby/Serene_Core
- Serene AI: https://github.com/jfilby/Serene_AI
The database is PostgreSQL v18.
Challenges we ran into
- Limited media resources
Both audio and image (media) resources were limited:
Audio: I didn't register before 4th Dec 2025 and therefor didn't qualify for the ElevenLabs' coupon. Fortunately someone on the hackathon's DevPost forum was donating an API key (although limited until Jan 12th). I'll look into options to making credits available after that.
Images: I kept getting a 429 (quota expired) error when trying to generate images with Gemini 2.5 Flash Image. Therefor these were left out of the slideshows.
- Varying tones for ElevenLabs speech
Initially the speech from ElevenLabs voices sounded monotonous. I read up on how ElevenLabs provides voice settings to simulate tones. With that knowledge (and some help from Gemini) I was able to create a set of pre-defined tones that matched the theme of the app.
Now when AI speech is generated, e.g. narration of slides, each sentence has a matching tone selected by the Gemini LLM. This gives a rich blend of tones that sounds amazing!
- Issues integrating with Yahoo! Finance
I started to get strange errors regarding cookies/crumbs, which seemed to be related to the platform blocking suspicious IPs. Fortunately these errors were not present on the Production server, deployed to Google Cloud.
Accomplishments that we're proud of
Use of ElevenLabs SDK: as mentioned earlier, this greatly enhances the user experience.
Uses Gemini APIs to power chats and the investment decision engine. This is integrated via Serene AI, one of my own Node.js libraries.
AI-driven investment research made a reality, opening up new possibilities for those that want to leverage AI for ideas or actual investments.
What we learned
What's next for Aitradefi
I want to continue building the project and evaluate its use for actual investment decisions.
Built With
- apollo
- elevenlabs
- gcp
- gemini
- graphql
- nextjs
- postgresql
- prisma
- serene-libs
- typescript
Log in or sign up for Devpost to join the conversation.