Skip to main content
QUICK REVIEW

[Paper Review] CFGPT: Chinese Financial Assistant with Large Language Model

Jiangtong Li, Yuxuan Bian|arXiv (Cornell University)|Sep 19, 2023
Stock Market Forecasting MethodsDecision Sciences5 citations
TL;DR

CFGPT is a Chinese financial large language model framework that integrates a curated financial dataset (CFData), a fine-tuned 7B-parameter LLM (CFLLM), and a real-world deployment system (CFAPP). Trained on 141B tokens for pre-training and 1.5B tokens for supervised fine-tuning across six financial tasks, it achieves strong zero-shot and few-shot performance in Chinese financial NLP, with code and models released open-source for community use.

ABSTRACT

Large language models (LLMs) have demonstrated great potential in natural language processing tasks within the financial domain. In this work, we present a Chinese Financial Generative Pre-trained Transformer framework, named CFGPT, which includes a dataset~(CFData) for pre-training and supervised fine-tuning, a financial LLM~(CFLLM) to adeptly manage financial texts, and a deployment framework~(CFAPP) designed to navigate real-world financial applications. The CFData comprising both a pre-training dataset and a supervised fine-tuning dataset, where the pre-training dataset collates Chinese financial data and analytics, alongside a smaller subset of general-purpose text with 584M documents and 141B tokens in total, and the supervised fine-tuning dataset is tailored for six distinct financial tasks, embodying various facets of financial analysis and decision-making with 1.5M instruction pairs and 1.5B tokens in total. The CFLLM, which is based on InternLM-7B to balance the model capability and size, is trained on CFData in two stage, continued pre-training and supervised fine-tuning. The CFAPP is centered on large language models (LLMs) and augmented with additional modules to ensure multifaceted functionality in real-world application. Our codes are released at https://github.com/TongjiFinLab/CFGPT.

Motivation & Objective

  • To address the lack of domain-specific large language models for Chinese financial text by developing a dedicated framework.
  • To construct a comprehensive Chinese financial dataset (CFData) combining pre-training and supervised fine-tuning data for financial NLP tasks.
  • To train a financial-optimized LLM (CFLLM) on CFData using two-stage training: continued pre-training and supervised fine-tuning.
  • To design a practical deployment framework (CFAPP) supporting diverse input formats and output types for real-world financial applications.
  • To release open-source code and models to advance research and application in Chinese financial LLMs.

Proposed method

  • Constructed CFData, a dual-part dataset: 584M documents (141B tokens) for pre-training and 1.5M instruction pairs (1.5B tokens) for supervised fine-tuning across six financial tasks.
  • Selected InternLM-7B as the base model to balance performance and efficiency, enabling effective adaptation to financial language.
  • Applied two-stage training: first continued pre-training on the financial and general Chinese corpus, then supervised fine-tuning on task-specific instruction pairs.
  • Designed CFAPP as a modular deployment system centered on LLMs, integrating vector databases, chain-of-thought reasoning, and domain-specific modules to enhance response accuracy and reliability.
  • Enabled multimodal input support (text, audio, PDF) and multiple output formats (raw text, templates, mind maps) to improve usability in real financial settings.
  • Supported extensibility to other LLMs beyond InternLM-7B, enhancing framework flexibility.

Experimental results

Research questions

  • RQ1Can a domain-specific large language model trained on a curated Chinese financial dataset achieve superior performance on financial NLP tasks compared to general-purpose LLMs?
  • RQ2How effective is two-stage training—continued pre-training followed by supervised fine-tuning—on enhancing zero-shot and few-shot capabilities in Chinese financial text understanding?
  • RQ3To what extent can a modular deployment framework (CFAPP) support diverse input formats and output types in real-world financial applications?
  • RQ4How does the integration of vector databases and chain-of-thought reasoning improve factual accuracy and reasoning in financial LLM responses?
  • RQ5What is the impact of domain-specific fine-tuning on tasks such as sentiment analysis, event detection, and stock movement prediction in the Chinese financial context?

Key findings

  • The CFLLM-ins-7B model demonstrated strong performance across six financial tasks, validating the effectiveness of domain-specific continued pre-training and supervised fine-tuning.
  • The CFData dataset, with 141B tokens for pre-training and 1.5B tokens for fine-tuning, provides a comprehensive resource for training Chinese financial LLMs.
  • The CFAPP framework successfully supports diverse input types (text, audio, PDF) and output formats (raw text, templates, mind maps), enhancing real-world usability.
  • Integration of vector databases and chain-of-thought modules improved response reliability and factual consistency in financial reasoning tasks.
  • The open-sourcing of code, models, and datasets via GitHub is expected to accelerate research and innovation in Chinese financial LLMs.
  • Initial evaluations confirmed the model’s capability in zero-shot and few-shot settings, particularly in sentiment analysis, summarization, and question-answering on financial texts.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.