Using TFire with LLMs

TFire is optimized to be effectively used together with Large Language Models (LLMs) like Claude or ChatGPT. TFire comes with a tailor-made documentation file (found under Downloads) specifically made to be attached when using an LLM.

Note

It is recommended to use an LLM with a large context window (e.g. 100k + tokens) like Claude 3.5.

Example Workflow

  1. Strategy Development:
# 1. Include documentation
[Paste or attach LLM documentation]

# 2. Describe strategy
"Help me create a momentum strategy that:
- Uses RSI and MACD indicators
- Buys when RSI crosses above 30
- Sells when RSI crosses above 70
- Implements proper error handling"

# 3. Receive and review code

Common Use Cases

  1. Creating New Layers
# Example prompt:
"'Help me create a new Layer that implements Relative Strength Index (RSI) calculations."
  1. Building Trading Strategies
# Example prompt:
"Implement a strategy that buys when the 50-day moving average crosses above the 200-day moving average."
  1. Debugging Code
# Paste code and error message
# Example prompt:
"What might be causing this issue?"

Effective Prompting

Structure your requests like this:

Context: [Paste relevant TFire documentation]

Task: Help me implement [your specific requirement]

Additional requirements:
- [Any specific constraints]
- [Performance considerations]
- [Error handling needs]

Do:

  1. Be Specific: Clearly describe your requirements and any constraints
  2. Include Context: Provide relevant documentation sections
  3. Iterate: Start simple and gradually add complexity
  4. Validate: Always test generated code thoroughly
  5. Ask for Explanations: Have the LLM explain the code it generates

Don't:

  1. Don't assume LLMs have current documentation - always provide it
  2. Don't rely on LLMs for numerical accuracy - test thoroughly
  3. Avoid asking for complex strategies without providing context