Kline is a powerful tool that combines a browser extension with an AI backend to provide instant technical analysis for any financial chart on the web. Simply capture a portion of your screen, and Kline's AI will deliver a detailed breakdown of trends, key levels, indicators, and actionable scenarios.
- Instant Chart Capture: Activate the extension with a click or a keyboard shortcut (
Ctrl+Shift+A) to select any chart on any website. - AI-Powered Analysis: Leverages Google's powerful Gemini 1.5 Flash vision model to interpret chart images with high accuracy.
- Comprehensive Reports: The AI generates a structured report covering:
- Chart Overview: Asset, timeframe, current trend, strength, and volatility.
- Key Levels: Automatically identifies major and minor support and resistance levels.
- Technical Signals: Detects chart patterns and reads values from common indicators (RSI, MAs, etc.).
- Actionable Insights: Provides objective bullish/bearish scenarios and a concise "Trader's Take".
- Seamless On-Page UI: The analysis is displayed in a clean, modern, and non-intrusive sidebar directly on your current page.
- Backend: Python, FastAPI, Google Gemini API, Uvicorn
- Browser Extension: JavaScript (ES6+), HTML5, CSS3, Chrome Extension APIs (Manifest V3)
Follow these instructions to set up and run the Kline project on your local machine.
- Python 3.8+
- A Google Chrome-based browser (Chrome, Brave, Edge, etc.)
- A Google AI (Gemini) API Key. You can get one from Google AI Studio.
First, set up the Python server that will run the AI analysis.
-
Clone the repository:
git clone [https://github.com/your-username/kline.git](https://github.com/your-username/kline.git) cd kline/backend -
Create and activate a virtual environment:
- On macOS/Linux:
python3 -m venv venv source venv/bin/activate - On Windows:
python -m venv venv .\venv\Scripts\activate
- On macOS/Linux:
-
Install the required dependencies:
pip install -r requirements.txt
-
Create an environment file: Create a file named
.envinside thebackenddirectory and add your Gemini API key:# backend/.env GEMINI_API_KEY="YOUR_API_KEY_HERE"
-
Run the backend server:
uvicorn main:app --reload
The server should now be running at
http://127.0.0.1:8000. You can visit this URL in your browser to see the status message:{"status":"AI Chart Analyzer API is running."}. Keep this terminal window open.
Next, load the extension into your browser.
- Open your Chrome-based browser and navigate to
chrome://extensions. - Enable "Developer mode" using the toggle switch, usually found in the top-right corner.
- Click the "Load unpacked" button.
- In the file selection dialog, navigate to the project folder and select the
extensiondirectory. - The "AI Chart Analyzer" extension should now appear in your list of extensions. It's recommended to "pin" it to your toolbar for easy access.
- Ensure the backend server is running (from step 1.5).
- Navigate to any webpage that displays a financial chart (e.g., TradingView, Yahoo Finance, etc.).
- Click the Kline extension icon in your browser toolbar or use the keyboard shortcut
Ctrl+Shift+A(orCmd+Shift+Aon Mac). - The screen will dim, and your cursor will become a crosshair. Click and drag to draw a box around the chart area you want to analyze.
- Release the mouse button. The selection will be sent for analysis.
- Within a few seconds, the analysis report will appear in a sidebar on the right side of the page.