Horizon

Inspiration

As retail traders ourselves, we are often overwhelmed by the amount of information and metrics available for every company. While this information can be understood with enough time and research, it is easy to overlook how a new trade fits into your overall portfolio. An individual investment might look like a great opportunity on its own, but could expose you to much greater risk when combined with your existing holdings, financial situation, and goals. We want to shift the focus from “Is this stock good? or should I buy” → “Does this trade make sense for my portfolio?”

What it does

Horizon is a conversational multi-agent financial assistant built on ASI. You can give it your portfolio and a financial goal, then ask about a potential trade. Horizon looks at the trade from two sides. Our Wellbeing Agent looks at the user's financial situation, including mock bank balances from Capital One Nessie, income, bills, available cash, and existing sector exposure. Our Trade Agent analyzes the investment itself, including fundamentals, risk, and potential profit, and generates debate between bull cases and bear cases. The Orchestrator brings those perspectives together and compares the trade's risk with how much room the user actually has. It doesn’t tell the user to explicitly buy or not buy a stock, and instead explains the trade in the context of the user's goals and finances. If the trade is eligible for a transfer, the user can approve it directly. In our demo, Horizon moves only the safe amount of $2,500 rather than all $5,000 available cash. The proposed stock is then added to the user's portfolio data to simulate an asset purchase. We also built a read-only dashboard that shows the same decision, including portfolio holdings, cash, sector exposure, and transfers.

How we built it

Horizon is built with three Fetch.ai uAgents communicating through mailboxes using a shared message contract and request IDs. The orchestrator is the only agent the user interacts with through ASI:One. It parses the user's message, sends the relevant fields to the Wellbeing and Trade agents, and combines their responses. The Wellbeing Agent uses Capital One Nessie data to calculate safe cash and sector exposure by looking through ETF holdings. The Trade Agent loads fundamentals from a local cache or yfinance and calculates risk and profit scores in code. ASI:One generates the bull and bear arguments around those scores. We also built the system to handle slow or unavailable responses gracefully, so the orchestrator can still return the information that was successfully received.

Challenges we ran into

One challenge we had was connecting the Wellbeing Agent with the bull and bear analysis. At first, they were looking at the trade from two separate perspectives. The Trade Agent focused on whether the stock looked like a good investment, while the Wellbeing Agent focused on whether the user could afford the trade. We had to make the orchestrator bring these results together so that a strong investment case could still be rejected if it did not fit the user's financial situation. We also had trouble getting the agent properly respond to the user message because we original hardcoded the function that the agent should make at each step. This create significant user experience issue because the user can complete break the agent by sending some message that orchestrator cannot parse. Eventually we found that we should break the orchestrator's abilities into small, well-defined tools, such as adding or removing an asset in the portfolio, updating the goal or hold length, running a trade check, and confirming a transfer. With those tools, the agent can use its understanding of the conversation to choose the right action for each message, instead of following rigid rules that fail on any input they weren't written for.

Accomplishments that we're proud of

We are especially proud of building our first multi-agent system and getting multiple agents to communicate and work together in one application. It was a new experience for us, and we learned how to design the agents, handle their communication, and combine their different outputs into one useful response.

What we learned

We learned that clear communication between agents is really important when building a multi-agent system. Freezing our message contract and giving every request a request ID made it much easier for the agents to work together.

What's next for Horizon

  • Our next step is to support real users instead of one shared demo customer, with separate financial data and more flexible portfolio inputs.
  • We want to consider more strategy such as selling stocks or shorting a asset.
  • We also want to improve our scoring by adding factors like volatility, how soon the user needs their money, and more detailed portfolio risk.
  • We originally planned for seven specialized agents, but reduced it to three so we could build a more reliable system within the hackathon.
  • With more time, we would expand the agent ecosystem again, with more specialized agents for areas like market news, macroeconomic trends, and deeper fundamental analysis.
  • We also want to host the system on cloud infrastructure like AWS, improve the communication between agents, and expand the dashboard to support multiple users and sessions.

Built With

Share this project:

Updates

Submission history