Skip to content
项目

yuedai-pbc/FINESSE-Financial-Reasoning-Agent

在 GitHub 查看

关于

FINESSE 的参考实现:具备自我反思能力的多智能体金融推理,支持动态专家路由和伦理验证。

商业与金融

这些数字如何统计

实测星标增长

24小时
0
7天
-1
15天
+49
1个月
正在收集历史

各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。

README.md

原文

FINESSE

Self-Reflective Multi-Agent Financial Reasoning with Dynamic Expert Routing and Ethical Verification

FINESSE is a reference implementation of a multi-agent architecture for explainable, retrieval-grounded, and ethically verified financial reasoning. It decomposes complex financial queries into dependent subtasks, routes each subtask to specialized experts, coordinates structured debate, and verifies the resulting consensus before returning a response.

FINESSE overall architecture

The system combines five specialist roles - Investment, Risk, Macro, Ethics, and Quantitative analysis - with a planner, dynamic top-k router, financial memory, retrieval-augmented grounding, self-reflective debate, and a final verifier.

Architecture at a glance

  1. Hierarchical planner - converts a complex financial query into a directed acyclic graph of subtasks.
  2. Dynamic expert router - activates the most relevant LoRA specialists while accounting for load and latency.
  3. Dual-stream grounding - combines semantic retrieval from a financial corpus with gated persistent memory.
  4. Self-reflective debate - allows specialists to challenge, refine, and consolidate their analyses.
  5. Verifier and ethics audit - checks the consensus and can return feedback to the planner for another pass.

Hierarchical task decomposition

Hierarchical task decomposition and parallel execution

The planner organizes subtasks by topological depth. Independent nodes at the same depth can run in parallel, reducing the critical execution path from the number of subtasks to the graph depth.

Latency-aware dynamic expert routing

Top-k dynamic expert routing

Each subtask embedding is scored against the expert pool. The router activates a top-k subset and aggregates their outputs, while auxiliary objectives encourage balanced expert utilization and latency-aware routing.

Retrieval and persistent financial memory

Retrieval-augmented grounding and financial memory

FINESSE uses adaptive semantic chunking and FAISS-based retrieval for external grounding. A gated key-value memory stores reusable financial reasoning traces and supplies relevant context to later subtasks.

Repository contents

FINESSE/
|-- main.py
|-- requirements.txt
|-- baselines/
|-- data/
|-- src/
|   |-- task_planner.py
|   |-- expert_router.py
|   |-- expert_agents.py
|   |-- debate_protocol.py
|   |-- rag_module.py
|   |-- memory_bank.py
|   |-- ethics_module.py
|   |-- evaluation.py
|   `-- finesse_pipeline.py
|-- assets/
`-- PUBLIC_RELEASE_AUDIT.md

Installation

python -m venv .venv
source .venv/bin/activate  # Windows: .venv\Scripts\activate
pip install -r requirements.txt

Configure an OpenAI-compatible model endpoint without committing credentials:

export TYPHOON_API_BASE="https://your-endpoint.example/v1"
export TYPHOON_API_KEY="your-key"

For a local OpenAI-compatible server, use OPENAI_API_BASE and OPENAI_API_KEY. Never place a real key in source files or Git history.

Usage

python main.py --help
python main.py demo
python main.py evaluate

Release scope and reproducibility

This public package contains the inference-oriented architecture, evaluation utilities, baseline clients, configuration, and small synthetic/example data files. It is not a full reproduction bundle for the paper's reported training run.

The following items are not included:

  • trained model weights or LoRA adapters;
  • the complete benchmark and financial knowledge base;
  • training infrastructure and trained router/ethics checkpoints;
  • the exact environment required to reproduce the paper's reported tables.

The train command in main.py is currently a placeholder. Randomly initialized planner, router, and ethics components are suitable for code inspection and API demonstrations, not for reproducing the paper's reported evaluation without trained parameters.

See PUBLIC_RELEASE_AUDIT.md for the publication review, exclusions, and remaining reproducibility gaps.

Data and model licensing

The bundled CSV files and knowledge-base text are examples only. Before publishing this repository, the authors must confirm that they created these files or otherwise have redistribution rights.

Model users must separately comply with the licenses and access terms of Typhoon2, Llama, Qwen, embedding models, and their selected inference provider.

License

No software license has been selected in this draft release. Add a license only after all authors agree and confirm that they have the right to license every included file. Until then, public visibility does not grant reuse rights.

Citation

Add the final arXiv identifier and BibTeX entry after the submission is publicly announced.

探索相关项目

加载中…