bhaskartripathi commited on
Commit
9e68166
·
verified ·
1 Parent(s): 4a5a37e

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +174 -72
README.md CHANGED
@@ -3,48 +3,174 @@ base_model: EleutherAI/gpt-neo-125M
3
  library_name: peft
4
  ---
5
 
6
- # Model Card for GPT-Neo 125M Market Analysis Model
 
 
 
7
 
8
- This model is a fine-tuned version of GPT-Neo 125M for financial market analysis and prediction. It specializes in identifying technical patterns, analyzing market sentiment, assessing risk, and generating trading strategy recommendations.
9
 
10
- ## Model Details
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
11
 
12
- ### Model Description
 
 
13
 
14
- The GPT-Neo 125M Market Analysis Model is designed for analyzing stock market data, specifically focusing on the Indian market. It uses fine-tuning through QLoRA (Quantized Low-Rank Adaptation) to adjust the base GPT-Neo 125M model for recognizing market patterns, interpreting sentiment, and providing trading insights.
 
 
15
 
16
- - **Developed by:** Bhaskar Tripathi
17
- - **Model type:** Causal Language Model (LLM) with financial analysis adaptations
18
- - **Language(s) (NLP):** English
19
- - **License:** Apache 2.0
20
- - **Finetuned from model:** EleutherAI/gpt-neo-125M
21
 
22
- ### Model Sources
23
- - **Repository:** [Hugging Face Hub Repository](https://huggingface.co/bhaskartripathi/GPT_Neo_Market_Analysis)
24
 
25
- ## Uses
 
 
26
 
27
- ### Direct Use
28
- The model can be used directly for generating market insights, interpreting technical analysis, and making sentiment-based predictions. It is intended for market analysts, traders, and financial researchers interested in automated market analysis and predictions.
 
29
 
30
- ### Downstream Use
31
- The model can be further fine-tuned for specific financial tasks, integrated into trading bots, or used in financial research applications to provide advanced automated analysis.
 
32
 
33
- ### Out-of-Scope Use
34
- The model should not be used as the sole basis for making financial decisions. It is not intended for high-frequency trading or as a substitute for human financial advisors. Misuse in making critical financial decisions without human verification could lead to significant financial losses.
 
35
 
36
- ## Bias, Risks, and Limitations
37
 
38
- - The model is specifically tuned for the Indian stock market, and its effectiveness may be limited in other markets.
39
- - Predictions are based on historical data and patterns recognized by the model, which may not account for unexpected market events or real-time data changes.
40
- - Users should not solely rely on the model for investment decisions; independent verification and diverse sources of market information are recommended.
41
 
42
- ### Recommendations
43
- Users should always verify the model’s outputs against other market data and perform independent analysis to mitigate risks. Financial professionals should be aware of potential biases and use this model as a supplementary tool.
 
44
 
45
- ## How to Get Started with the Model
46
- Use the code below to get started with the model.
 
47
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
48
  ```python
49
  from transformers import AutoTokenizer, AutoModelForCausalLM
50
 
@@ -65,66 +191,42 @@ Based on this technical analysis, what is the likely price movement for tomorrow
65
  inputs = tokenizer(input_text, return_tensors="pt")
66
  outputs = model.generate(**inputs, max_new_tokens=50)
67
  result = tokenizer.decode(outputs[0], skip_special_tokens=True)
68
-
69
- print(result)
70
  ```
71
 
72
  ## Training Details
73
 
74
- ### Training Data
75
- The model was fine-tuned using a custom dataset of Indian stock market data, including technical analysis patterns, trading signals, market sentiment, and risk metrics. The dataset included historical market prices, technical indicators, news sentiment, and other financial metrics.
76
-
77
- ### Training Procedure
78
- - **Training regime:** Mixed precision training (fp16) with QLoRA for efficient parameter adaptation using 4-bit quantization.
79
- - **Hardware Type:** Nvidia T4 GPU
80
- - **Hours used:** Approximately 6 hours
81
-
82
- ## Evaluation
83
-
84
- ### Testing Data, Factors & Metrics
85
-
86
- #### Testing Data
87
- The model was evaluated on a validation dataset from the Indian stock market, which includes unseen technical analysis data, price movements, and sentiment data.
88
 
89
- #### Metrics
90
- - **Prediction Accuracy**: Evaluated for market movements.
91
- - **Sentiment Correlation**: Assessed for accuracy in sentiment interpretation from news and social media.
92
- - **Pattern Recognition Precision**: Accuracy in detecting predefined technical patterns.
93
 
94
- ### Results
95
- The model performed well on predicting price movements based on technical analysis and sentiment inputs, with high accuracy in identifying well-known technical patterns.
96
 
97
- ## Environmental Impact
98
- - **Hardware Type:** Nvidia T4 GPU
99
- - **Hours used:** Approximately 6 hours
100
- - **Carbon Emitted:** Estimated using [ML CO2 Impact Calculator](https://mlco2.github.io/impact#compute).
101
 
102
- ## Technical Specifications
103
 
104
- ### Model Architecture and Objective
105
- The model uses the GPT-Neo 125M architecture, fine-tuned using QLoRA for efficient adaptation to financial analysis tasks.
106
-
107
- ### Compute Infrastructure
108
- The model was fine-tuned using Google Colab Pro with an Nvidia T4 GPU.
109
 
110
  ## Citation
111
- If you use this model, please cite:
112
-
113
  ```bibtex
114
- @misc{tripathi2024gptneomarket,
115
- title={GPT-Neo 125M Market Analysis Model},
116
  author={Bhaskar Tripathi},
117
  year={2024},
118
  url={https://huggingface.co/bhaskartripathi/GPT_Neo_Market_Analysis}
119
  }
120
  ```
121
 
122
- ## More Information
123
- For more information, reach out to [Bhaskar Tripathi](https://huggingface.co/bhaskartripathi).
124
-
125
- ## Model Card Contact
126
- For any questions or issues, please contact: bhaskartripathi@domain.com
127
-
128
- ### Framework versions
129
- - PEFT 0.13.2
130
-
 
3
  library_name: peft
4
  ---
5
 
6
+ ---
7
+ base_model: EleutherAI/gpt-neo-125M
8
+ library_name: peft
9
+ ---
10
 
11
+ # Model Card for Bharat Market Analysis: IndicFinGPT-Neo
12
 
13
+ ## भारतीय बाजार की पहली AI मॉडल (India's First Market Analysis LLM)
14
+
15
+ IndicFinGPT is a pioneering Large Language Model (LLM) fine-tuned exclusively for the Indian stock market. It represents a significant advancement in utilizing cutting-edge AI technology to understand and analyze Bharatiya financial ecosystems, bridging the gap between global AI innovations and India's unique trading dynamics.
16
+
17
+ ## Key Highlights
18
+
19
+ IndicFinGPT
20
+ India's first Large Language Model fine-tuned for financial market analysis, built on GPT-Neo 125M architecture.
21
+ Key Highlights
22
+ IndicFinGPT is the first LLM tailored for Indian financial markets, providing in-depth insights into:
23
+
24
+ Trading Patterns: Specialized in recognizing BSE/NSE-specific patterns and cycles
25
+ Market Sentiment: Built-in understanding of Indian market sentiment and cultural influences
26
+ Economic Indicators: Adapted to domestic economic and financial metrics
27
+ Local Influences: Awareness of timing, festival impacts, and market-specific volatility
28
+
29
+ Core Capabilities
30
+
31
+ Technical Pattern Recognition:
32
+
33
+ - **Head and Shoulders patterns**
34
+ - What are the implications of a Head and Shoulders pattern forming for Tata Consultancy Services (TCS) in the upcoming week?
35
+ - How does the identification of a Head and Shoulders pattern for Reliance Industries influence its potential price movement?
36
+
37
+ - **Double Top/Bottom patterns**
38
+ - What is the expected market behavior for Infosys if a Double Top pattern has formed over the last two weeks?
39
+ - How does a Double Bottom pattern in Tata Steel indicate a possible upward trend?
40
+
41
+ - **Triangle formations**
42
+ - What trading opportunities are indicated by a symmetrical triangle formation in Hindustan Unilever?
43
+ - How could an ascending triangle in Tata Motors impact its price performance in the coming days?
44
+
45
+ - **Flag patterns**
46
+ - What are the implications of a bullish flag pattern for the stock of Infosys in the short term?
47
+ - How can a flag pattern formation in Reliance Industries affect trading strategies for the next three days?
48
+
49
+ - **Wedge patterns**
50
+ - How does a rising wedge pattern in Tata Steel signal a potential market reversal?
51
+ - What are the likely outcomes of a falling wedge pattern detected in Tata Consultancy Services (TCS)?
52
+
53
+ - **Cup and Handle patterns**
54
+ - Can you provide an analysis of a Cup and Handle pattern formation in Hindustan Unilever?
55
+ - How could a Cup and Handle pattern affect the price movement of Reliance Industries in the coming week?
56
+
57
+ Earnings Analysis:
58
+
59
+ - **Key metrics extraction**
60
+ - What are the key earnings metrics extracted for Infosys for the latest quarter?
61
+ - How do the extracted financial metrics for Tata Motors compare to previous earnings?
62
+
63
+ - **Historical comparisons**
64
+ - How does the historical earnings performance of Tata Consultancy Services (TCS) compare to the current quarter?
65
+ - What insights can be gained by comparing historical earnings of Hindustan Unilever over the last three years?
66
+
67
+ - **Red flag identification**
68
+ - Are there any red flags in the latest earnings report of Reliance Industries?
69
+ - What potential risks are identified in Tata Steel's financial report?
70
+
71
+ - **Positive indicator detection**
72
+ - What are the positive financial indicators in the latest earnings of Tata Motors?
73
+ - How do the positive indicators for Infosys reflect its market position?
74
+
75
+ Market Sentiment Interpretation:
76
+
77
+ - **Price-based sentiment analysis**
78
+ - How does the recent price movement of Reliance Industries reflect market sentiment?
79
+ - What sentiment indicators can be derived from the price fluctuations of Tata Steel?
80
 
81
+ - **News sentiment analysis**
82
+ - How might recent news regarding Tata Consultancy Services (TCS) impact its stock price in the next few days?
83
+ - What is the sentiment derived from the latest business news about Hindustan Unilever?
84
 
85
+ - **Social media sentiment analysis**
86
+ - How is social media sentiment trending for Infosys, and what impact could this have on its stock price?
87
+ - What does the current social media sentiment indicate about Tata Motors in the upcoming week?
88
 
89
+ - **Sentiment divergence calculation**
90
+ - How does the divergence between price-based sentiment and news sentiment impact the outlook for Tata Consultancy Services (TCS)?
91
+ - What are the implications of a sentiment divergence for Reliance Industries over the next few days?
 
 
92
 
93
+ Risk Assessment:
 
94
 
95
+ - **Volatility analysis**
96
+ - What does the volatility analysis indicate for Tata Steel over the next week?
97
+ - How volatile is the stock of Hindustan Unilever in the current market scenario?
98
 
99
+ - **Beta calculation**
100
+ - How does the beta of Tata Motors compare to other companies in the Nifty 50 index?
101
+ - What does the beta calculation imply about the risk associated with Infosys?
102
 
103
+ - **Value at Risk (VaR) computation**
104
+ - What is the VaR for Reliance Industries, considering the current market conditions?
105
+ - How does the VaR for Tata Consultancy Services (TCS) help in understanding the potential risk in the next three days?
106
 
107
+ - **Risk rating determination**
108
+ - How is the risk rating for Hindustan Unilever determined based on current data?
109
+ - What is the risk rating for Tata Steel, and how could it influence trading strategies?
110
 
111
+ Trading Strategy Recommendations:
112
 
113
+ - **Pattern-based analysis**
114
+ - What are the potential trading opportunities for Reliance Industries based on recent flag or wedge pattern formations in the next week?
115
+ - How does the Double Top pattern for Tata Steel indicate a possible trend reversal in the coming days?
116
 
117
+ - **Sentiment-driven insights**
118
+ - How might recent news and social media sentiment affect the stock price of Infosys over the next three days?
119
+ - What is the current sentiment regarding Tata Consultancy Services (TCS), and how could it impact its performance over the next week?
120
 
121
+ - **Risk-adjusted recommendations**
122
+ - What are the risk-adjusted trading strategies for Infosys in light of current market volatility?
123
+ - Based on beta calculations and current market sentiment, what are the recommended actions for Tata Steel in the coming days?
124
 
125
+ - **Historical context integration**
126
+ - How have similar market conditions in the past affected the performance of Hindustan Unilever, and what can be expected this week?
127
+ - Considering past Diwali trading patterns, what is the expected impact on Reliance Industries this year?
128
+
129
+ ### Sample Questions to Ask the Model
130
+
131
+ - What are the potential trading strategies for Nifty 50 based on the current market patterns?
132
+ - How does the market sentiment from recent news articles impact the stock price of Reliance Industries?
133
+ - What are the key risk indicators for the portfolio containing Tata Consultancy Services (TCS), Infosys, and Tata Steel?
134
+ - Can you provide an analysis of the Cup and Handle pattern formation for Hindustan Unilever?
135
+ - What are the potential effects of Diwali on the Indian stock market this year?
136
+
137
+ Model Details
138
+
139
+ Base Model: EleutherAI/gpt-neo-125M
140
+ Training Data: 6 years of Indian market data (Nifty 50 + 50 companies)
141
+ Fine-tuning: QLoRA implementation
142
+
143
+ ## Model Details
144
+
145
+ - **Base Model**: EleutherAI/gpt-neo-125M
146
+ - **Developer**: Bhaskar Tripathi
147
+ - **License**: Apache 2.0
148
+ - **Repository**: [Hugging Face Hub](https://huggingface.co/bhaskartripathi/GPT_Neo_Market_Analysis)
149
+ - **Coverage**: Focused on Nifty 50 and 50 additional Indian companies
150
+ - **Historical Data**: Trained on 6 years of Indian market movements and data patterns
151
+
152
+ ## Market Understanding
153
+
154
+ ### Technical Analysis Expertise
155
+ The model is adept at identifying crucial market formations including:
156
+ - **Classical Patterns**: Head & Shoulders, Double Top/Bottom, Triangle, Flag, Wedge, Cup and Handle.
157
+ - **Advanced Techniques**: Local support and resistance levels, volume analysis, and momentum indicators specifically tailored to Indian volatility.
158
+
159
+ ### Market Intelligence
160
+ IndicFinGPT includes:
161
+ - **Comprehensive Financial Reports**: Analysis of quarterly and annual earnings.
162
+ - **Multi-source Sentiment Analysis**: Incorporates data from Indian business news, social media, and even informal platforms like WhatsApp and Telegram groups.
163
+ - **Risk Metrics**: Indian-adapted VaR, Beta, and volatility models.
164
+
165
+ ### Cultural Context in Trading
166
+ Culturally aware strategies include:
167
+ - **Indian Market Timing**: Recommendations tailored to pre-market, regular, and post-market phases.
168
+ - **Festival & Cultural Factors**: Insights into events like Diwali (Muhurat Trading), budget announcements, and investor sentiment.
169
+ - **FII/DII Flow and Retail Behavior**: Specific guidance considering both institutional and retail dynamics.
170
+
171
+ ## Implementation
172
+
173
+ ### Quick Start
174
  ```python
175
  from transformers import AutoTokenizer, AutoModelForCausalLM
176
 
 
191
  inputs = tokenizer(input_text, return_tensors="pt")
192
  outputs = model.generate(**inputs, max_new_tokens=50)
193
  result = tokenizer.decode(outputs[0], skip_special_tokens=True)
 
 
194
  ```
195
 
196
  ## Training Details
197
 
198
+ ### Dataset and Fine-tuning
199
+ - **Dataset**: Comprehensive dataset featuring 6 years of Indian market data.
200
+ - **Method**: Fine-tuned using QLoRA (4-bit quantization) for optimal efficiency.
201
+ - **Training Infrastructure**: Utilized an Nvidia T4 GPU, trained for ~6 hours with PEFT framework version 0.13.2.
 
 
 
 
 
 
 
 
 
 
202
 
203
+ ## Performance Metrics
204
+ - **Pattern Recognition**: High accuracy in classical and advanced pattern detection in Indian markets.
205
+ - **Sentiment Correlation**: Strong alignment with local market movements.
206
+ - **Risk & Volatility Handling**: Reliable risk analysis in volatile market conditions.
207
 
208
+ ## Use Cases
 
209
 
210
+ - **Automated Market Analysis**: Insight generation for Indian stock portfolios.
211
+ - **Strategy Development**: Recommendations for traders in local markets.
212
+ - **Risk Management**: Portfolio analysis and risk mitigation insights.
213
+ - **Educational Utility**: Training tool for new traders learning about Indian markets.
214
 
215
+ ## Social Impact
216
 
217
+ IndicFinGPT democratizes sophisticated AI-based financial analysis for the Indian stock market, providing affordable and accessible tools for both seasoned investors and new traders.
 
 
 
 
218
 
219
  ## Citation
 
 
220
  ```bibtex
221
+ @misc{tripathi2024indicfin,
222
+ title={IndicFinGPT: Market Analysis Model for Indian Stocks},
223
  author={Bhaskar Tripathi},
224
  year={2024},
225
  url={https://huggingface.co/bhaskartripathi/GPT_Neo_Market_Analysis}
226
  }
227
  ```
228
 
229
+ ## Contact
230
+ - **Email**: bhaskar.tripathi@volkswagen.co.in
231
+ - **HuggingFace**: [@bhaskartripathi](https://huggingface.co/bhaskartripathi)
232
+ - **Google Scholar**: [Profile](https://scholar.google.com/citations?user=SCHOLAR_ID)