Overview
Use Claude Code inside the Claude Desktop app to write a small local Python tracker that records your own regular and one-off investments and works out a money-weighted return for each holding.
Problem or Objective
- Which agents turn a plain-language brief into a working app or prototype?
- Which agents clean, chart and explain a dataset you provide?
More in Finance and Admin
AI Agents and Models
Tools and Integrations
- Tools
- Claude Desktop · Claude Code · pandas · Python
- Prerequisites
- Claude Desktop with Claude Code (the Help Center plan table lists Claude Code on paid plans; check yours), Python with pandas, and a transaction export from your broker.
How It Works
Open Claude Code in the Claude Desktop app on a paid plan and point it at an empty project folder. Export your own transactions from your broker as a CSV file with date, holding, amount and units, and save it in that folder. Ask Claude Code to write a Python script that loads the file into a pandas DataFrame, marks each row as a recurring instalment or a one-off purchase, groups the rows by holding, and computes the invested total, current value from a price file you keep up to date, and a money-weighted annual return from the dated cash flows. pandas is one way to build this. Review each file change Claude proposes before accepting it. Run the script, then check two or three holdings by hand against a spreadsheet return formula before you rely on the numbers.
Implementation Workflow
Steps assembled from the agents, tools and prompt of this entry. Adapt them to your own setup.
- Choose the agentSet up Claude Code, Claude Desktop.
- Connect the toolsConnect the tools this workflow relies on: Claude Desktop, Claude Code, pandas, Python.
- Check the prerequisitesClaude Desktop with Claude Code (the Help Center plan table lists Claude Code on paid plans; check yours), Python with pandas, and a transaction export from your broker.
- Gather your detailsCollect what the prompt asks for: Transaction export file, How to spot recurring instalments, File with current prices, Report file name.
- Run the starter promptPaste the starter prompt below into Claude Code and adapt it to your case.
- Check against the documentationCompare what you get with the documentation at claude.com before you rely on it.
Practical Starter Prompt: Write a personal investment tracker
Fill the fields to adapt the prompt. Empty fields stay as visible [placeholders].
In this folder, write a Python script that reads [Transaction export file] (columns: date, holding, amount, units) with pandas. Label each row as recurring or one-off using [How to spot recurring instalments]. Group by holding and report the invested total, the current value using prices from [File with current prices], and a money-weighted annual return from the dated cash flows. Print a table and save it as [Report file name]. Show me each file change before you make it, and do not give buy or sell advice.pandas is one way to build this. Approve each file change Claude Code proposes, run the script yourself, and compare a few returns with a spreadsheet formula before trusting them. Treat the output as a record of your own history, not advice.
Expected Results and Benefits
This is a suggested workflow, not a reported result. The points below are what the cited documentation says the tools can do.
This is a suggested workflow, not a reported outcome. The Claude download page documents Claude Code running inside the desktop app with review of local code changes, and the pandas README describes the data structures the script would use. No cited page shows a portfolio tracker or a money-weighted return calculation, so the correctness of the code Claude writes is untested here.
Limitations and Considerations
This is not financial advice: the tracker reports past cash flows and does not tell you what to buy or sell, and a person decides. Check the return figures against your broker statement or a spreadsheet before relying on them. Keep the transaction export on your own computer and leave account passwords out of the project. Claude apps are on every plan, but some features are paid-only; the Help Center plan table shows Claude Code on paid plans, so check your plan. Results depend on your setup and were not independently reproduced by Top 200 Repos.
GitHub Repositories
AI Agent Repository
Source code of the agent that does the work.
Suggested Implementation Component
A repository that could serve as a building block. It is not part of the cited account and is not evidence that the workflow was run.
Related Videos
About anthropics/claude-code
The SECRET Claude Code Upgrade That Has Everyone Going Nuts (Full Guide) (opens in a new tab)
The title names the project, the description links the project website.
Watch on YouTube (opens in a new tab)About anthropics/claude-code
The only Claude Code guide you'll ever need (Opus 4.5) (opens in a new tab)
The title names the project, the description links the project website.
Watch on YouTube (opens in a new tab)Independent creators. Listing a video implies no endorsement, sponsorship or partnership.
Sources
- Download Claude | Claude by Anthropic (opens in a new tab)
Project documentation · claude.com · Undated · Source checked 26 Nov 2026, 17:27 UTC
What this source supports
- Claude Code runs directly in the desktop app.
- You can preview running servers, review local code changes, and monitor pull request status without leaving the app.
- Some features are only available to paid plans.
- Install Claude Desktop | Claude Help Center (opens in a new tab)
Project documentation · support.claude.com · Undated · Source checked 26 Nov 2026, 17:27 UTC
What this source supports
- Claude Desktop is available on macOS, Windows, and Linux (beta).
- pandas-dev/pandas README (opens in a new tab)
Project documentation · github.com · Undated · Source checked 25 Nov 2026, 12:00 UTC
What this source supports
- pandas is a Python package that provides fast, flexible, and expressive data structures designed to make working with "relational" or "labeled" data both easy and intuitive.

