Inspiration
Project evaluation generally involves assessing alternatives based on their projected cash flows. Two key criteria are typically used: Net Present Value (NPV) and Internal Rate of Return (IRR). The goal of this project was to design an agent that would receive a written instruction in natural language, including the project's cash flow data, and return its NPV and IRR. Furthermore, this agent should have the capability to evaluate multiple alternatives simultaneously, using the aforementioned criteria.
Features
- Natural Language Processing: Describe investment projects in plain English
- Financial Analysis: Automatic NPV and IRR calculations using proven financial formulas
- AI-Powered Extraction: CrewAI agents extract financial parameters from project descriptions
- Local LLM: Uses Ollama with gemma3n:e2b model for secure, local processing
- Web Interface: Clean, intuitive Gradio interface for easy interaction
- Investment Recommendations: Clear APPROVE/REJECT decisions with detailed reasoning
What it does
A conversational AI system that evaluates investment projects using natural language input. The system leverages CrewAI for multi-agent orchestration, Ollama for local LLM inference, and Gradio for the user interface. Investment decisions are based on NPV (Net Present Value) and IRR (Internal Rate of Return) calculations.
How we built it
- I developed the NPV and IRR functions in Python.
- I created a detailed prompt outlining the goals I wanted to achieve with this project.
- Using Kiro, I initiated the process of defining the project's goals, specifications, and tasks, leveraging the Kiro Specs feature and Claude Sonnet as a language model.
- Once the tasks were defined, I monitored the results within an iterative process of continuous improvement.
Challenges we ran into
The Kiro interface is very similar to VSCode, making it quite intuitive to use. Developing a process from scratch was much more challenging. I created four versions of the project. In the first three versions, I initially used a library of economic engineering I developed myself. This could serve as a starting point for the LLM (Large Language Model) used by Kiro to design a robust API. The key issue is that vague or poorly detailed specifications allow the LLM to deviate from the intended goal.
In the first version, the LLM created a fully functional API, but it functioned like a financial calculator. It installed programs that weren't necessary or that, based on the initial plan, should have been specified but weren't actually used in the API. It also developed financial mathematics functions without considering the code I had provided.
It was very difficult to get it to work within a project environment; it consistently worked or installed in the base environment. It installed a lot of unnecessary "junk." This was very frustrating.
After several trials and a couple of weeks running Kiro, I realized that I needed to be more specific and reduce the number of functions. I switched from a library to only a few functions related to NPV (Net Present Value) and IRR (Internal Rate of Return). The initial prompt I gave it was much more detailed and provided a clearer context, effectively limiting the working environment and the scope of the project.
Accomplishments that we're proud of
I believe this is the first time anyone has created something like this. It's fully functional, runs locally, and it's designed to automate economic evaluation tasks within the company. I'm proud of the result – it's practical and functional despite its seemingly simple design.
What we learned
Developing in this manner requires a very clear understanding of the desired functionalities. It's crucial to define the context clearly and concisely. Establish boundaries, environments, and restrictions from the outset. Maintain continuous monitoring of the development process. And most importantly, do not leave the API development unsupervised.
What's next for AI Investment Evaluator
Improve the UI design and enhance the prompts for agents to better evaluate complex scenarios using natural language.
Built With
- crewai
- gradio
- langchain
- ollama
- python
Log in or sign up for Devpost to join the conversation.